/* ========================================
   ROYAL PORTFOLIO - CSS STYLESHEET
   ======================================== */

/* ========================================
   CSS CUSTOM PROPERTIES (VARIABLES)
   ======================================== */
:root {
    /* Royal Color Palette */
    --navy-dark: #0a1128;
    --navy-medium: #1e2749;
    --navy-light: #2d3561;
    --gold-primary: #d4af37;
    --gold-light: #f4d03f;
    --gold-dark: #b8941e;
    --white: #ffffff;
    --white-soft: #f8f9fa;
    --gray-light: #e0e0e0;
    --gray-medium: #9e9e9e;

    /* Typography */
    --font-serif: 'Playfair Display', serif;
    --font-sans: 'Inter', sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-medium: 0.4s ease;
    --transition-slow: 0.6s ease;

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.3);
    --shadow-gold: 0 4px 20px rgba(212, 175, 55, 0.3);
}

/* Dark Mode Variables */
body.dark-mode {
    --navy-dark: #0d1117;
    --navy-medium: #161b22;
    --navy-light: #21262d;
    --white: #c9d1d9;
    --white-soft: #8b949e;
    --gray-light: #30363d;
}

/* ========================================
   GLOBAL RESET & BASE STYLES
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-sans);
    background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy-medium) 100%);
    color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* ========================================
   LOADING ANIMATION
   ======================================== */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--navy-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    transition: opacity 0.5s, visibility 0.5s;
}

.page-loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-content {
    text-align: center;
}

.royal-spinner {
    width: 80px;
    height: 80px;
    border: 4px solid var(--navy-light);
    border-top: 4px solid var(--gold-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.loader-text {
    color: var(--gold-primary);
    font-family: var(--font-serif);
    font-size: 1.2rem;
    letter-spacing: 2px;
}

/* ========================================
   SCROLL PROGRESS INDICATOR
   ======================================== */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(90deg, var(--gold-primary), var(--gold-light));
    z-index: 9999;
    transition: width 0.1s ease;
}

/* ========================================
   NAVIGATION BAR
   ======================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1rem 5%;
    background: rgba(10, 17, 40, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    z-index: 1000;
    transition: all var(--transition-medium);
}

.navbar.scrolled {
    padding: 0.5rem 5%;
    box-shadow: var(--shadow-lg);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-serif);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--gold-primary);
    text-decoration: none;
    letter-spacing: 1px;
    transition: all var(--transition-fast);
}

.logo:hover {
    color: var(--gold-light);
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.5);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    padding: 0.5rem 0;
    transition: color var(--transition-fast);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold-primary);
    transition: width var(--transition-medium);
}

.nav-link:hover {
    color: var(--gold-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.dark-mode-toggle {
    background: transparent;
    border: 2px solid var(--gold-primary);
    color: var(--gold-primary);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    cursor: pointer;
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.dark-mode-toggle:hover {
    background: var(--gold-primary);
    color: var(--navy-dark);
    transform: scale(1.05);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--gold-primary);
    transition: all var(--transition-fast);
}

/* ========================================
   FLOATING BACKGROUND SHAPES
   ======================================== */
.floating-shapes {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.shape {
    position: absolute;
    opacity: 0.1;
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 300px;
    height: 300px;
    background: var(--gold-primary);
    border-radius: 50%;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 200px;
    height: 200px;
    background: var(--gold-light);
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    top: 60%;
    right: 10%;
    animation-delay: 5s;
}

.shape-3 {
    width: 150px;
    height: 150px;
    background: var(--gold-primary);
    transform: rotate(45deg);
    bottom: 20%;
    left: 20%;
    animation-delay: 10s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-50px) rotate(180deg);
    }
}

/* ========================================
   HERO SECTION
   ======================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-lg) 5%;
    position: relative;
    z-index: 1;
}

.hero-content {
    max-width: 1400px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text h1 {
    font-family: var(--font-serif);
    font-size: 4rem;
    color: var(--gold-primary);
    margin-bottom: 1rem;
    line-height: 1.2;
    animation: fadeInUp 1s ease;
}

.hero-text .subtitle {
    font-size: 1.5rem;
    color: var(--white-soft);
    margin-bottom: 1.5rem;
    animation: fadeInUp 1.2s ease;
}

.hero-text .intro {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 2rem;
    color: var(--gray-light);
    animation: fadeInUp 1.4s ease;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    animation: fadeInUp 1.6s ease;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all var(--transition-medium);
    display: inline-block;
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold-primary), var(--gold-light));
    color: var(--navy-dark);
    box-shadow: var(--shadow-gold);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(212, 175, 55, 0.5);
}

.btn-secondary {
    background: transparent;
    color: var(--gold-primary);
    border: 2px solid var(--gold-primary);
}

.btn-secondary:hover {
    background: var(--gold-primary);
    color: var(--navy-dark);
    transform: translateY(-3px);
}

/* ========================================
   TECH ORBIT ANIMATION (Hero Section)
   ======================================== */
.hero-3d {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.tech-orbit-wrapper {
    width: 420px;
    height: 420px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Central glowing core */
.tech-core {
    position: absolute;
    width: 130px;
    height: 130px;
    background: radial-gradient(circle at 35% 35%, rgba(244, 208, 63, 0.25), rgba(212, 175, 55, 0.08));
    border-radius: 50%;
    border: 2px solid rgba(212, 175, 55, 0.5);
    box-shadow:
        0 0 40px rgba(212, 175, 55, 0.4),
        0 0 80px rgba(212, 175, 55, 0.2),
        inset 0 0 30px rgba(212, 175, 55, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: corePulse 4s ease-in-out infinite;
    z-index: 5;
}

@keyframes corePulse {

    0%,
    100% {
        box-shadow: 0 0 40px rgba(212, 175, 55, 0.4), 0 0 80px rgba(212, 175, 55, 0.2);
        transform: scale(1);
    }

    50% {
        box-shadow: 0 0 60px rgba(212, 175, 55, 0.7), 0 0 110px rgba(212, 175, 55, 0.35);
        transform: scale(1.06);
    }
}

/* Orbit rings — each ring rotates, the icon counter-rotates to stay upright */
.orbit-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px dashed rgba(212, 175, 55, 0.2);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.orbit-icon {
    position: absolute;
    top: -29px;
    width: 58px;
    height: 58px;
    background: rgba(10, 17, 40, 0.85);
    border: 2px solid rgba(212, 175, 55, 0.45);
    border-radius: 50%;
    padding: 7px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4), 0 0 16px rgba(212, 175, 55, 0.25);
    transition: box-shadow 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.orbit-icon:hover {
    box-shadow: 0 4px 25px rgba(212, 175, 55, 0.6), 0 0 30px rgba(212, 175, 55, 0.3);
}

/* Single orbit ring — rotates as one unit, icons fixed 90° apart */
.single-ring {
    position: absolute;
    width: 360px;
    height: 360px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: singleRingRotate 14s linear infinite;
}

/* Icons inside single-ring: positioned via inline style transforms in HTML.
   They counter-rotate to stay upright. */
.single-ring .orbit-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    margin-top: -29px;
    margin-left: -29px;
    animation: iconStayUpright 14s linear infinite;
}

@keyframes singleRingRotate {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes iconStayUpright {
    from {
        transform: rotate(0deg) translateY(-160px) rotate(0deg);
    }

    to {
        transform: rotate(360deg) translateY(-160px) rotate(-360deg);
    }
}

/* Override per-icon to set their fixed starting angle */
.single-ring .orbit-icon:nth-child(1) {
    animation: icon0 14s linear infinite;
}

.single-ring .orbit-icon:nth-child(2) {
    animation: icon90 14s linear infinite;
}

.single-ring .orbit-icon:nth-child(3) {
    animation: icon180 14s linear infinite;
}

.single-ring .orbit-icon:nth-child(4) {
    animation: icon270 14s linear infinite;
}

@keyframes icon0 {
    from {
        transform: rotate(0deg) translateY(-160px) rotate(0deg);
    }

    to {
        transform: rotate(360deg) translateY(-160px) rotate(-300deg);
    }
}

@keyframes icon90 {
    from {
        transform: rotate(90deg) translateY(-160px) rotate(-90deg);
    }

    to {
        transform: rotate(450deg) translateY(-160px) rotate(-390deg);
    }
}

@keyframes icon180 {
    from {
        transform: rotate(180deg) translateY(-160px) rotate(-180deg);
    }

    to {
        transform: rotate(540deg) translateY(-160px) rotate(-480deg);
    }
}

@keyframes icon270 {
    from {
        transform: rotate(270deg) translateY(-160px) rotate(-270deg);
    }

    to {
        transform: rotate(630deg) translateY(-160px) rotate(-570deg);
    }
}

@keyframes ringRotate {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes iconCounter {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(-360deg);
    }
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   SECTIONS
   ======================================== */
section {
    padding: var(--spacing-xl) 5%;
    position: relative;
    z-index: 1;
}

.section-title {
    font-family: var(--font-serif);
    font-size: 3rem;
    color: var(--gold-primary);
    text-align: center;
    margin-bottom: var(--spacing-lg);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, transparent, var(--gold-primary), transparent);
    margin: 1rem auto 0;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

/* ========================================
   GLASS CARDS
   ======================================== */
.glass-card {
    background: rgba(30, 39, 73, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 20px;
    padding: var(--spacing-md);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-medium);
}

.glass-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg), var(--shadow-gold);
    border-color: var(--gold-primary);
}

/* ========================================
   TIMELINE (About Page)
   ======================================== */
.timeline {
    position: relative;
    padding: 2rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--gold-primary);
    transform: translateX(-50%);
}

.timeline-item {
    margin-bottom: 3rem;
    position: relative;
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-left: auto;
    text-align: left;
}

.timeline-content {
    width: 45%;
    background: rgba(30, 39, 73, 0.6);
    backdrop-filter: blur(10px);
    padding: 2rem;
    border-radius: 15px;
    border: 1px solid rgba(212, 175, 55, 0.2);
    position: relative;
    transition: all var(--transition-medium);
}

.timeline-content:hover {
    transform: scale(1.05);
    border-color: var(--gold-primary);
    box-shadow: var(--shadow-gold);
}

.timeline-dot {
    position: absolute;
    left: 50%;
    top: 0;
    width: 20px;
    height: 20px;
    background: var(--gold-primary);
    border-radius: 50%;
    transform: translateX(-50%);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.6);
}

/* ========================================
   SKILLS PAGE
   ======================================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.skill-card {
    background: rgba(30, 39, 73, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 20px;
    padding: 2rem;
    transition: all var(--transition-medium);
    transform-style: preserve-3d;
}

.skill-card:hover {
    transform: translateY(-10px) rotateX(5deg) rotateY(5deg);
    box-shadow: 0 20px 40px rgba(212, 175, 55, 0.3);
    border-color: var(--gold-primary);
}

.skill-card h3 {
    font-family: var(--font-serif);
    color: var(--gold-primary);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.skill-item {
    margin-bottom: 1.5rem;
}

.skill-name {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.skill-bar {
    width: 100%;
    height: 10px;
    background: var(--navy-light);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.skill-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--gold-primary), var(--gold-light));
    border-radius: 10px;
    width: 0;
    transition: width 1.5s ease;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
}

.skill-card.animate .skill-progress {
    width: var(--progress);
}

/* ========================================
   PROJECT CARDS
   ======================================== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.project-card {
    background: rgba(30, 39, 73, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 20px;
    padding: 2rem;
    transition: all var(--transition-medium);
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.1), transparent);
    opacity: 0;
    transition: opacity var(--transition-medium);
    pointer-events: none;
}

.project-card:hover::before {
    opacity: 1;
}

.project-card:hover {
    transform: translateY(-15px);
    box-shadow: 0 20px 50px rgba(212, 175, 55, 0.3);
    border-color: var(--gold-primary);
}

.project-card h3 {
    font-family: var(--font-serif);
    color: var(--gold-primary);
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.project-tag {
    display: inline-block;
    background: rgba(212, 175, 55, 0.2);
    color: var(--gold-light);
    padding: 0.3rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
}

/* ========================================
   CONTACT FORM
   ======================================== */
.contact-container {
    max-width: 800px;
    margin: 0 auto;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.contact-item {
    background: rgba(30, 39, 73, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
    transition: all var(--transition-medium);
}

.contact-item:hover {
    transform: translateY(-5px);
    border-color: var(--gold-primary);
    box-shadow: var(--shadow-gold);
}

.contact-item i {
    font-size: 2rem;
    color: var(--gold-primary);
    margin-bottom: 1rem;
}

.contact-form {
    background: rgba(30, 39, 73, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 20px;
    padding: 3rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    color: var(--gold-primary);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: rgba(10, 17, 40, 0.5);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 10px;
    color: var(--white);
    font-family: var(--font-sans);
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--gold-primary);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

/* Flash Messages */
.flash-messages {
    margin-bottom: 2rem;
}

.flash {
    padding: 1rem 1.5rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    animation: slideInDown 0.5s ease;
}

.flash.success {
    background: rgba(76, 175, 80, 0.2);
    border: 1px solid #4caf50;
    color: #81c784;
}

.flash.error {
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid #f44336;
    color: #e57373;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   FOOTER
   ======================================== */
footer {
    background: rgba(10, 17, 40, 0.95);
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    padding: 3rem 5%;
    text-align: center;
    position: relative;
    z-index: 1;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
}

.social-link {
    color: var(--gold-primary);
    font-size: 1.5rem;
    transition: all var(--transition-fast);
}

.social-link:hover {
    color: var(--gold-light);
    transform: translateY(-5px);
}

.footer-text {
    color: var(--white-soft);
    font-size: 0.9rem;
}

/* ========================================
   FADE-IN ANIMATION ON SCROLL
   ======================================== */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-text h1 {
        font-size: 3rem;
    }

    .rotating-gear {
        width: 300px;
        height: 300px;
    }

    .timeline::before {
        left: 30px;
    }

    .timeline-content {
        width: calc(100% - 80px);
        margin-left: 80px !important;
    }

    .timeline-dot {
        left: 30px;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: rgba(10, 17, 40, 0.98);
        flex-direction: column;
        padding: 2rem;
        transition: left var(--transition-medium);
    }

    .nav-menu.active {
        left: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .hero-text h1 {
        font-size: 2.5rem;
    }

    .hero-text .subtitle {
        font-size: 1.2rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .rotating-gear {
        width: 250px;
        height: 250px;
    }

    .projects-grid,
    .skills-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 2rem;
    }

    .rotating-gear {
        width: 200px;
        height: 200px;
    }

    .contact-form {
        padding: 1.5rem;
    }
}

/* ========================================
   UTILITY CLASSES
   ======================================== */
.text-center {
    text-align: center;
}

.mt-1 {
    margin-top: var(--spacing-sm);
}

.mt-2 {
    margin-top: var(--spacing-md);
}

.mt-3 {
    margin-top: var(--spacing-lg);
}

.mb-1 {
    margin-bottom: var(--spacing-sm);
}

.mb-2 {
    margin-bottom: var(--spacing-md);
}

.btn-edit {
    padding: 0.35rem 0.8rem;
    background: rgba(212, 175, 55, 0.12);
    border: 1px solid rgba(212, 175, 55, 0.35);
    color: var(--gold-primary);
    border-radius: 6px;
    font-size: 0.82rem;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-edit:hover {
    background: rgba(212, 175, 55, 0.28);
}

/* Modals */
.admin-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 10, 25, 0.85);
    backdrop-filter: blur(8px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.admin-modal.active {
    display: flex;
}

.modal-content {
    background: #0a1128;
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 16px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2.5rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.modal-header h2 {
    color: var(--gold-primary);
    margin: 0;
    font-size: 1.5rem;
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--white-muted);
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: var(--gold-primary);
}


/* ========================================
   ADMIN & LOGIN STYLES (Desktop)
   ======================================== */

.admin-wrapper {
    min-height: 100vh;
    padding: 6rem 1.5rem 4rem;
    position: relative;
    z-index: 2;
    background: rgba(10, 17, 40, 0.6);
}

.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto 2.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.admin-header h1 {
    font-family: var(--font-serif);
    color: var(--gold-primary);
    font-size: 2.2rem;
    margin: 0;
}

.admin-header h1 span {
    font-size: 1rem;
    color: var(--white-muted);
    font-family: var(--font-sans);
    font-weight: 400;
    display: block;
    margin-top: 0.2rem;
}

.admin-logout-btn {
    padding: 0.6rem 1.4rem;
    background: rgba(220, 53, 69, 0.15);
    border: 1px solid rgba(220, 53, 69, 0.4);
    color: #ff6b7a;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.2s;
}

.admin-logout-btn:hover {
    background: rgba(220, 53, 69, 0.3);
}

/* Flash Messages */
.admin-flash {
    max-width: 1200px;
    margin: 0 auto 2.5rem;
    width: 100%;
}

.flash-msg {
    padding: 1.2rem 1.5rem;
    border-radius: 12px;
    margin-bottom: 1rem;
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    backdrop-filter: blur(10px);
    animation: slideInDown 0.4s ease-out;
}

.flash-msg.success {
    background: rgba(40, 167, 69, 0.15);
    border: 1px solid rgba(40, 167, 69, 0.3);
    color: #4cd137;
}

.flash-msg.error {
    background: rgba(220, 53, 69, 0.15);
    border: 1px solid rgba(220, 53, 69, 0.3);
    color: #ff6b7a;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.2rem;
    max-width: 1200px;
    margin: 0 auto 2.5rem;
}

.stat-card {
    background: rgba(10, 17, 40, 0.8);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    backdrop-filter: blur(10px);
}

.stat-card .stat-num {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--gold-primary);
    line-height: 1;
}

.stat-card .stat-label {
    color: var(--white-muted);
    font-size: 0.85rem;
    margin-top: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.admin-tabs {
    display: flex;
    gap: 0.5rem;
    max-width: 1200px;
    margin: 0 auto 2rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    padding-bottom: 0;
    flex-wrap: wrap;
}

.admin-tab-btn {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--white-muted);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
    margin-bottom: -1px;
}

.admin-tab-btn.active,
.admin-tab-btn:hover {
    color: var(--gold-primary);
    border-bottom-color: var(--gold-primary);
}

.admin-panel {
    display: none;
    max-width: 1200px;
    margin: 0 auto;
}

.admin-panel.active {
    display: block;
}

.admin-section {
    background: rgba(10, 17, 40, 0.8);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
    backdrop-filter: blur(10px);
}

.admin-section h2 {
    color: var(--gold-primary);
    font-size: 1.3rem;
    margin: 0 0 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.15);
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.admin-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    align-items: end;
}

.admin-form.single-col {
    grid-template-columns: 1fr;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group label {
    color: var(--gold-light);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.7rem 0.9rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 8px;
    color: #ffffff;
    font-size: 0.95rem;
    transition: border-color 0.3s;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--gold-primary);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.12);
    color: #ffffff;
}

.form-group input:-webkit-autofill {
    -webkit-text-fill-color: #ffffff;
    -webkit-box-shadow: 0 0 0px 1000px #1a2240 inset;
    transition: background-color 5000s ease-in-out 0s;
}

.form-group select option {
    background: #0a1128;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.btn-add {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #d4af37, #f0d060);
    color: #0a1128;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    white-space: nowrap;
    align-self: flex-end;
}

.btn-add:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.35);
}

.admin-table-wrap {
    overflow-x: auto;
    margin-top: 1.5rem;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.admin-table th {
    background: rgba(212, 175, 55, 0.1);
    color: var(--gold-primary);
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.admin-table td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--white-soft);
    vertical-align: middle;
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.7rem;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-primary);
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.progress-mini {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.progress-mini-bar {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    min-width: 80px;
}

.progress-mini-fill {
    height: 100%;
    background: linear-gradient(90deg, #d4af37, #f0d060);
    border-radius: 3px;
}

.btn-delete {
    padding: 0.35rem 0.8rem;
    background: rgba(220, 53, 69, 0.12);
    border: 1px solid rgba(220, 53, 69, 0.35);
    color: #ff6b7a;
    border-radius: 6px;
    font-size: 0.82rem;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-delete:hover {
    background: rgba(220, 53, 69, 0.28);
}

.message-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 10px;
    padding: 1.2rem 1.4rem;
    margin-bottom: 1rem;
}

.message-meta {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.6rem;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.message-sender {
    font-weight: 600;
    color: var(--gold-primary);
}

.message-email {
    color: var(--white-muted);
    font-size: 0.85rem;
}

.message-body {
    color: var(--white-soft);
    line-height: 1.7;
    font-size: 0.92rem;
    white-space: pre-wrap;
}

/* Admin Login Page Stylings */
.admin-login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.admin-login-card {
    background: rgba(10, 17, 40, 0.95);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(212, 175, 55, 0.05);
    backdrop-filter: blur(20px);
    text-align: center;
}

.admin-login-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #d4af37, #f0d060);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: #0a1128;
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.4);
}

.admin-login-card h1 {
    font-family: var(--font-serif);
    color: var(--gold-primary);
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.admin-form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.admin-form-group label {
    display: block;
    color: var(--gold-light);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.admin-form-group input {
    width: 100%;
    padding: 0.85rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.admin-login-btn {
    width: 100%;
    padding: 0.9rem;
    background: linear-gradient(135deg, #d4af37, #f0d060);
    color: #0a1128;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 0.5rem;
}