:root {
    --gt-gold: #FFD700;
    --gt-pink: #FF1493;
    --gt-dark: #1a1a1a;
    --gt-darker: #0d0d0d;
}

body {
    background-color: var(--gt-dark);
    font-family: 'Microsoft YaHei', sans-serif;
    overflow-x: hidden;
    animation: shamate-bg-flash 0.5s infinite; /* Shamate strobe effect */
}

html, body {
    touch-action: manipulation;
}

/* Shamate Flash Animations */
@keyframes shamate-bg-flash {
    0% { background-color: var(--gt-dark); }
    25% { background-color: #2a002a; }
    50% { background-color: #001a00; }
    75% { background-color: #000033; }
    100% { background-color: var(--gt-dark); }
}

@keyframes shamate-text-flash {
    0% { color: #ff0000; text-shadow: 2px 2px 0px #00ff00; }
    25% { color: #00ff00; text-shadow: -2px 2px 0px #0000ff; }
    50% { color: #0000ff; text-shadow: -2px -2px 0px #ff0000; }
    75% { color: #ffff00; text-shadow: 2px -2px 0px #ff00ff; }
    100% { color: #ff00ff; text-shadow: 2px 2px 0px #00ffff; }
}

/* Header Styling */
.gt-header {
    /* background: linear-gradient(135deg, var(--gt-darker) 0%, #2a2a2a 100%); REMOVED to let animation show */
    border-bottom: 5px solid var(--gt-gold);
    position: relative;
    overflow: hidden;
    animation: shamate-bg-flash 0.5s infinite; /* Add Shamate background effect to header */
}

/* Specific override for Header H1 to not flash */
.gt-header h1.text-shadow-animate {
    animation: none;
    color: var(--gt-gold);
    text-shadow: 0 0 10px var(--gt-gold);
}

/* Removed shamate-border-flash animation from header and keeping border static */

@keyframes shamate-border-flash {
    0% { border-color: #ff0000; }
    33% { border-color: #00ff00; }
    66% { border-color: #0000ff; }
    100% { border-color: #ff0000; }
}

.gt-header::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 10px,
        rgba(255, 215, 0, 0.05) 10px,
        rgba(255, 215, 0, 0.05) 20px
    );
    pointer-events: none;
}

/* Typography & Animations */
.text-shadow-animate {
    color: var(--gt-gold);
    text-transform: uppercase;
    animation: shamate-text-flash 0.1s infinite alternate; /* Ultra fast text flash */
    font-weight: 900;
}

@keyframes glow {
    from {
        text-shadow: 0 0 10px var(--gt-gold), 0 0 20px var(--gt-gold);
    }
    to {
        text-shadow: 0 0 20px var(--gt-pink), 0 0 30px var(--gt-pink), 0 0 40px var(--gt-pink);
    }
}

/* Card Styling - Shamate Edition */
.gt-card {
    background: transparent; /* Changed from rgba to transparent for pseudo-element trick */
    /* border: 2px solid var(--gt-gold); Removed for animated border */
    border-radius: 15px;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    /* backdrop-filter: blur(5px); Moved to ::after */
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.gt-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: repeating-conic-gradient(
        transparent 0deg 10deg,
        #ff0000 10deg 20deg,
        transparent 20deg 30deg,
        #00ff00 30deg 40deg,
        transparent 40deg 50deg,
        #0000ff 50deg 60deg,
        transparent 60deg 70deg,
        #ffff00 70deg 80deg,
        transparent 80deg 90deg,
        #ff00ff 90deg 100deg
    );
    animation: shamate-rotate 2s linear infinite;
    z-index: -2;
}

.gt-card::after {
    content: '';
    position: absolute;
    inset: 4px; /* Thickness of the border */
    background: rgba(20, 20, 20, 0.9);
    border-radius: 12px;
    z-index: -1;
    backdrop-filter: blur(5px);
}

@keyframes shamate-rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.gt-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 25px rgba(255, 20, 147, 0.4);
    /* border-color: var(--gt-pink); Removed */
}

.gt-card:hover::before {
    animation-duration: 0.5s; /* Speed up on hover */
}

/* Image Styling */
.gt-profile-img {
    cursor: pointer;
    transition: transform 0.3s;
    max-width: 200px;
    width: 100%;
    height: auto;
}

/* Pulse Button Effect */
.pulse-btn {
    position: relative;
    overflow: hidden;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(255, 215, 0, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 215, 0, 0);
    }
}

/* Custom Tooltip */
.custom-tooltip {
    position: fixed;
    background: var(--gt-pink);
    color: white;
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: bold;
    pointer-events: none;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.2s, transform 0.2s;
    z-index: 9999;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    border: 2px solid white;
}

.custom-tooltip.active {
    opacity: 1;
    transform: scale(1);
}

/* Responsive & Touch Targets */
@media (max-width: 768px) {
    .btn {
        min-height: 48px; /* Touch target size */
    }
    
    .gt-header h1 {
        font-size: 2.5rem;
    }
}

/* Utility */
.text-pink {
    color: var(--gt-pink);
}

.bg-pink {
    background-color: var(--gt-pink);
}

/* =========================================
   NEW: Glowing Rotating Border for Main Title
   ========================================= */

/* Define custom property for smooth gradient rotation */
@property --angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

#gt-main-title {
    /* Ensure relative positioning for pseudo-elements */
    position: relative;
    /* Override previous specific styles to ensure clean slate */
    color: var(--gt-gold);
    /* Keep text readable */
    text-shadow: 0 0 5px rgba(0,0,0,0.5);
    z-index: 1;
}

/* The glowing rotating border */
#gt-main-title::before {
    content: attr(data-text);
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    
    /* Create the border effect using text-stroke */
    -webkit-text-stroke: 8px transparent;
    color: transparent;
    
    /* The rotating gradient */
    background-image: conic-gradient(
        from var(--angle), 
        #ff0000, #ff7f00, #ffff00, #00ff00, #0000ff, #4b0082, #8b00ff, #ff0000
    );
    
    /* Clip background to text shape */
    -webkit-background-clip: text;
    background-clip: text;
    
    /* Rotate animation */
    animation: rotate-gradient 3s linear infinite;
}

/* Optional: Add a blurred glow layer for stronger effect */
#gt-main-title::after {
    content: attr(data-text);
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    
    -webkit-text-stroke: 15px transparent;
    color: transparent;
    
    background-image: conic-gradient(
        from var(--angle), 
        #ff0000, #ff7f00, #ffff00, #00ff00, #0000ff, #4b0082, #8b00ff, #ff0000
    );
    
    -webkit-background-clip: text;
    background-clip: text;
    
    filter: blur(15px);
    opacity: 0.8;
    
    animation: rotate-gradient 3s linear infinite;
}

@keyframes rotate-gradient {
    to {
        --angle: 360deg;
    }
}

/* Music Control Button */
.music-control {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid var(--gt-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 0 10px var(--gt-gold);
    transition: transform 0.3s ease;
    user-select: none;
    /* Animation setup */
    animation: music-rotate 3s linear infinite;
    animation-play-state: paused; /* Default paused until playing */
}

.music-control.playing {
    animation-play-state: running;
    background: rgba(255, 215, 0, 0.2);
    box-shadow: 0 0 20px var(--gt-pink);
    border-color: var(--gt-pink);
}

.music-control:hover {
    transform: scale(1.1);
}

@keyframes music-rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Adjust for mobile */
@media (max-width: 768px) {
    .music-control {
        bottom: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
}
