/* Global Animation Improvements */
:root {
    --ease-out-back: cubic-bezier(0.175, 0.885, 0.32, 1.275);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Enhanced Signature Notification with 3D Flip */
.signature-toast {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 260px;
    height: 60px;
    perspective: 1000px;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
}

.signature-toast.active {
    animation: toastSlideIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards, 
               toastSlideOut 0.6s ease-in 6s forwards;
}

@keyframes toastSlideIn {
    0% { opacity: 0; transform: translateX(100px); }
    100% { opacity: 1; transform: translateX(0); }
}

@keyframes toastSlideOut {
    0% { opacity: 1; transform: translateX(0); }
    100% { opacity: 0; transform: translateX(100px); }
}

.toast-flipper {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    animation: flipSequence 5s ease-in-out infinite;
    /* Delays start of flip to let user read first */
    animation-delay: 1s; 
}

@keyframes flipSequence {
    0%, 30% { transform: rotateX(0); }
    40%, 90% { transform: rotateX(180deg); }
    100% { transform: rotateX(0); } /* Returns to start if looped, but we remove it before loop completes usually */
}

.toast-face {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    border: 1px solid var(--primary);
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.6);
}

.toast-face.back {
    transform: rotateX(180deg);
    background: rgba(20, 20, 0, 0.9);
    border-color: var(--primary);
}

.sig-text-main {
    font-size: 1.1rem;
    font-weight: 900;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.sig-text-sub {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ... Existing Styles ... */
:root {
    --primary: #FFFF00;
    --primary-dim: #b3b300;
    --bg-dark: #050505;
    --bg-card: #111111;
    --text-main: #ffffff;
    --text-sec: #888888;
    --glow-spread: 0 0 30px rgba(255, 255, 0, 0.15);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Background Effects */
.bg-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.glow-spot {
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 255, 0, 0.03) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 10s infinite ease-in-out;
}

.glow-1 { top: -10%; left: -10%; animation-delay: 0s; }
.glow-2 { bottom: -10%; right: -10%; animation-delay: 2s; }
.glow-3 { top: 40%; left: 60%; width: 400px; height: 400px; background: radial-gradient(circle, rgba(255, 255, 0, 0.02) 0%, transparent 70%); animation-delay: 4s; }

@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(30px, 20px); }
}

/* Layout */
.main-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Header / Hero */
header {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
}

.brand-title {
    font-size: 3.5rem;
    font-weight: 900;
    text-transform: uppercase;
    color: transparent;
    -webkit-text-stroke: 2px var(--primary);
    letter-spacing: 4px;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.brand-title::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    color: var(--primary);
    border-right: 4px solid var(--primary);
    overflow: hidden;
    animation: fillText 3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    white-space: nowrap;
}

@keyframes fillText {
    from { width: 0%; }
    to { width: 100%; border-right-color: transparent; }
}

.subtitle {
    color: var(--text-sec);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
    opacity: 0;
    animation: fadeIn 1s ease-out 2.5s forwards;
}

@keyframes fadeIn {
    to { opacity: 1; }
}

/* Content Grid */
.content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

/* Left Column: Profile & Info */
.left-col {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Profile Card - Enhanced */
.profile-card-container {
    width: 100%;
    height: 200px;
    perspective: 1500px;
    opacity: 0;
    animation: fadeInUp 0.8s ease-out 0.5s forwards;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.profile-card {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.profile-card:hover {
    transform: rotateX(10deg) rotateY(10deg);
}

.profile-card.flipped {
    transform: rotateY(180deg);
}

.card-face {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 0, 0.1);
    border-radius: 20px;
    overflow: hidden;
}

.card-face::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--primary);
    box-shadow: 0 0 20px var(--primary);
}

.front h2 {
    font-size: 2.5rem;
    color: #fff;
    margin-bottom: 0.5rem;
}

.front span {
    color: var(--primary);
    font-weight: bold;
    letter-spacing: 2px;
}

.back {
    transform: rotateY(180deg);
    background: #000;
    border: 2px solid var(--primary);
}

.back h2 {
    font-size: 2rem;
    color: var(--primary);
}

.back p {
    color: #fff;
    font-size: 1.2rem;
}

/* Mission Box - Floating Style */
.mission-container {
    background: linear-gradient(90deg, rgba(255,255,0,0.05), transparent);
    border-left: 4px solid var(--primary);
    padding: 1.5rem;
    position: relative;
    opacity: 0;
    animation: fadeInUp 0.8s ease-out 0.8s forwards;
}

.mission-text {
    font-size: 1.1rem;
    color: #ddd;
}

.mission-text strong {
    color: var(--primary);
}

/* Right Column: Navigation Cards */
.right-col {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.nav-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--bg-card);
    padding: 1.5rem 2rem;
    border-radius: 15px;
    text-decoration: none;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.05);
    transition: all 0.4s var(--ease-out-back);
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: slideInRight 0.6s ease-out forwards;
}

/* Staggered animation for nav items */
.nav-card:nth-child(1) { animation-delay: 1.0s; }
.nav-card:nth-child(2) { animation-delay: 1.2s; }
.nav-card:nth-child(3) { animation-delay: 1.4s; }
.nav-card:nth-child(4) { animation-delay: 1.6s; }

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

.nav-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background: var(--primary);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.nav-card:hover {
    transform: translateX(10px) scale(1.02);
    background: #1a1a1a;
    border-color: rgba(255,255,0,0.2);
    box-shadow: -10px 0 30px rgba(0,0,0,0.5);
}

.nav-card:hover::before {
    transform: scaleY(1);
}

.nav-info {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-icon {
    font-size: 2rem;
    color: var(--primary);
    width: 50px;
    text-align: center;
    transition: transform 0.3s ease;
}

.nav-card:hover .nav-icon {
    transform: scale(1.2) rotate(5deg);
}

.nav-text h3 {
    font-size: 1.2rem;
    margin-bottom: 0.3rem;
    font-weight: 700;
}

.nav-text p {
    font-size: 0.9rem;
    color: var(--text-sec);
}

.arrow-icon {
    color: var(--primary);
    opacity: 0;
    transform: translateX(-20px);
    transition: all 0.4s ease;
}

.nav-card:hover .arrow-icon {
    opacity: 1;
    transform: translateX(0);
}

.nav-card.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    filter: grayscale(1);
}

.nav-card.disabled:hover {
    transform: none;
}

/* Discord Specific */
.discord-card {
    background: linear-gradient(90deg, rgba(88, 101, 242, 0.1), transparent);
    border-color: rgba(88, 101, 242, 0.2);
}

.discord-card .nav-icon, .discord-card .arrow-icon {
    color: #5865F2;
}

.discord-card::before {
    background: #5865F2;
}

.discord-card:hover {
    border-color: #5865F2;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    margin-top: auto;
    border-top: 1px solid rgba(255,255,255,0.05);
    opacity: 0;
    animation: fadeIn 1s ease-out 2s forwards;
}

.footer-content {
    max-width: 600px;
    margin: 0 auto;
    color: var(--text-sec);
    font-size: 0.9rem;
}

.contact-highlight {
    color: var(--primary);
    font-weight: bold;
    text-decoration: none;
    margin-left: 0.5rem;
}

/* Notification (Standard) */
#notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.notification {
    background: #000;
    color: #fff;
    padding: 1rem 1.5rem;
    border: 1px solid var(--primary);
    box-shadow: 0 0 20px rgba(255,255,0,0.2);
    margin-bottom: 10px;
    border-radius: 4px;
    transform: translateX(120%);
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.notification.show { transform: translateX(0); }

/* Responsive */
@media (max-width: 900px) {
    .content-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .brand-title {
        font-size: 2.5rem;
    }
    
    .main-wrapper {
        padding: 1rem;
    }
    
    .profile-card-container {
        height: 180px;
    }
    
    .signature-toast {
        bottom: 20px;
        min-width: 90%;
        padding: 1rem;
    }
}
