/* mybadge.id - Dark Academia + Neon Electric Dashboard */

/* ========== RESET & BASE ========== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    background-color: #1A1410;
    color: #E8DFD0;
    font-family: 'Crimson Text', Georgia, serif;
    font-size: clamp(0.9rem, 1.2vw, 1.1rem);
    font-weight: 400;
    line-height: 1.65;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* ========== BLOB CONTAINER ========== */
#blob-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.atmo-blob {
    position: absolute;
    border-radius: 40% 60% 70% 30% / 50% 40% 60% 50%;
    opacity: 0.18;
    will-change: transform, border-radius;
    pointer-events: none;
}

.atmo-blob[data-color="blue"] {
    width: 380px;
    height: 380px;
    background: radial-gradient(circle at 40% 40%, #3B82F6 0%, transparent 70%);
    filter: blur(50px);
    border: 1px solid rgba(59, 130, 246, 0.5);
}

.atmo-blob[data-color="violet"] {
    width: 320px;
    height: 320px;
    background: radial-gradient(circle at 40% 40%, #A855F7 0%, transparent 70%);
    filter: blur(45px);
    border: 1px solid rgba(168, 85, 247, 0.5);
}

.atmo-blob[data-color="magenta"] {
    width: 280px;
    height: 280px;
    background: radial-gradient(circle at 40% 40%, #EC4899 0%, transparent 70%);
    filter: blur(55px);
    border: 1px solid rgba(236, 72, 153, 0.5);
}

.atmo-blob[data-color="amber"] {
    width: 250px;
    height: 250px;
    background: radial-gradient(circle at 40% 40%, #F59E0B 0%, transparent 70%);
    filter: blur(50px);
    border: 1px solid rgba(245, 158, 11, 0.5);
}

#blob-hero {
    top: 10%;
    left: 5%;
}

#blob-violet {
    top: 30%;
    right: 10%;
}

#blob-magenta {
    top: 60%;
    left: 20%;
}

#blob-amber {
    top: 75%;
    right: 25%;
}

/* ========== DASHBOARD GRID ========== */
#dashboard {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: 60px repeat(3, auto) auto auto auto auto;
    gap: clamp(1rem, 2vw, 1.5rem);
    max-width: 1400px;
    margin: 0 auto;
    padding: clamp(1rem, 2vw, 1.5rem);
    min-height: 100vh;
}

/* ========== HEADER STRIP ========== */
#header-strip {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 clamp(1rem, 2vw, 1.5rem);
    background-color: rgba(26, 20, 16, 0.85);
    border-bottom: 1px solid rgba(168, 85, 247, 0.15);
    backdrop-filter: blur(10px);
}

.header-logo {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: #E8DFD0;
}

.header-blob {
    width: 32px;
    height: 32px;
    border-radius: 40% 60% 50% 70%;
    background: radial-gradient(circle at 40% 40%, #A855F7 0%, transparent 70%);
    border: 1px solid rgba(168, 85, 247, 0.5);
    animation: headerPulse 3s ease-in-out infinite;
}

@keyframes headerPulse {
    0%, 100% { transform: scale(1); opacity: 0.7; }
    50% { transform: scale(1.15); opacity: 1; }
}

/* ========== HERO PANEL ========== */
#hero-panel {
    grid-column: 1 / 9;
    grid-row: 2 / 5;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    background-color: #2A1F1A;
    padding: clamp(1.5rem, 3vw, 2.5rem);
    display: flex;
    align-items: flex-end;
    min-height: 350px;
    border: 1px solid transparent;
    transition: transform 350ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
                border-color 350ms ease,
                box-shadow 350ms ease;
}

#hero-panel:hover {
    transform: scale(1.02);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 8px 32px rgba(59, 130, 246, 0.2);
}

.hero-texture {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 2px,
        rgba(232, 223, 208, 0.02) 2px,
        rgba(232, 223, 208, 0.02) 4px
    );
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    color: #E8DFD0;
    margin-bottom: 1rem;
}

.hero-subtitle {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: clamp(1rem, 1.5vw, 1.25rem);
    color: #8B7E72;
    max-width: 520px;
    line-height: 1.6;
}

/* ========== BADGE GRID ========== */
#badge-grid {
    grid-column: 9 / 13;
    grid-row: 2 / 5;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: clamp(0.75rem, 1.5vw, 1rem);
}

.badge-panel {
    position: relative;
    background-color: #2A1F1A;
    border-radius: 8px;
    padding: clamp(1rem, 2vw, 1.5rem);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    border-top: 3px solid transparent;
    border-left: 1px solid transparent;
    border-right: 1px solid transparent;
    border-bottom: 1px solid transparent;
    transition: transform 350ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
                border-color 350ms ease,
                box-shadow 350ms ease;
    overflow: hidden;
    /* Dark-academia texture */
    background-image: repeating-linear-gradient(
        -45deg,
        transparent,
        transparent 2px,
        rgba(232, 223, 208, 0.015) 2px,
        rgba(232, 223, 208, 0.015) 4px
    );
    background-color: #2A1F1A;
}

.badge-panel[data-accent="violet"] {
    border-top-color: #A855F7;
}
.badge-panel[data-accent="blue"] {
    border-top-color: #3B82F6;
}
.badge-panel[data-accent="magenta"] {
    border-top-color: #EC4899;
}
.badge-panel[data-accent="amber"] {
    border-top-color: #F59E0B;
}

.badge-panel:hover {
    transform: scale(1.02);
}

.badge-panel[data-accent="violet"]:hover {
    border-color: rgba(168, 85, 247, 0.4);
    border-top-color: #A855F7;
    box-shadow: 0 8px 32px rgba(168, 85, 247, 0.2);
}
.badge-panel[data-accent="blue"]:hover {
    border-color: rgba(59, 130, 246, 0.4);
    border-top-color: #3B82F6;
    box-shadow: 0 8px 32px rgba(59, 130, 246, 0.2);
}
.badge-panel[data-accent="magenta"]:hover {
    border-color: rgba(236, 72, 153, 0.4);
    border-top-color: #EC4899;
    box-shadow: 0 8px 32px rgba(236, 72, 153, 0.2);
}
.badge-panel[data-accent="amber"]:hover {
    border-color: rgba(245, 158, 11, 0.4);
    border-top-color: #F59E0B;
    box-shadow: 0 8px 32px rgba(245, 158, 11, 0.2);
}

/* Badge Blobs */
.badge-blob {
    width: 60px;
    height: 60px;
    border-radius: 40% 60% 70% 30% / 50% 40% 60% 50%;
    filter: blur(2px);
    margin-bottom: 0.75rem;
    will-change: transform, border-radius;
    animation: blobMorph 7s ease-in-out infinite alternate;
    transition: transform 300ms ease;
}

.badge-panel:hover .badge-blob {
    transform: scale(1.2);
    animation-duration: 3s;
}

.badge-blob[data-color="violet"] {
    background: radial-gradient(circle at 40% 40%, #A855F7 0%, transparent 70%);
    border: 1px solid rgba(168, 85, 247, 0.5);
}
.badge-blob[data-color="blue"] {
    background: radial-gradient(circle at 40% 40%, #3B82F6 0%, transparent 70%);
    border: 1px solid rgba(59, 130, 246, 0.5);
}
.badge-blob[data-color="magenta"] {
    background: radial-gradient(circle at 40% 40%, #EC4899 0%, transparent 70%);
    border: 1px solid rgba(236, 72, 153, 0.5);
}
.badge-blob[data-color="amber"] {
    background: radial-gradient(circle at 40% 40%, #F59E0B 0%, transparent 70%);
    border: 1px solid rgba(245, 158, 11, 0.5);
}

@keyframes blobMorph {
    0% { border-radius: 40% 60% 70% 30% / 50% 40% 60% 50%; }
    25% { border-radius: 60% 40% 30% 70% / 40% 60% 50% 50%; }
    50% { border-radius: 50% 50% 60% 40% / 60% 50% 40% 60%; }
    75% { border-radius: 30% 70% 40% 60% / 50% 60% 50% 40%; }
    100% { border-radius: 60% 40% 50% 50% / 40% 60% 40% 60%; }
}

.badge-label {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #8B7E72;
    margin-bottom: 0.25rem;
}

.badge-count {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: #E8DFD0;
}

/* ========== DETAIL PANELS ========== */
.detail-panel {
    position: relative;
    background-color: #2A1F1A;
    border-radius: 8px;
    padding: clamp(1.5rem, 3vw, 2.5rem);
    border: 1px solid transparent;
    transition: transform 350ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
                border-color 350ms ease,
                box-shadow 350ms ease;
    overflow: hidden;
    /* Dark-academia texture */
    background-image: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 2px,
        rgba(232, 223, 208, 0.02) 2px,
        rgba(232, 223, 208, 0.02) 4px
    );
    background-color: #2A1F1A;
}

.detail-panel:hover {
    transform: scale(1.02);
}

#detail-1 {
    grid-column: 1 / 9;
}
#detail-1:hover {
    border-color: rgba(168, 85, 247, 0.3);
    box-shadow: 0 8px 32px rgba(168, 85, 247, 0.15);
}

#detail-2 {
    grid-column: 9 / 13;
}
#detail-2:hover {
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: 0 8px 32px rgba(59, 130, 246, 0.15);
}

#detail-3 {
    grid-column: 1 / 5;
}
#detail-3:hover {
    border-color: rgba(236, 72, 153, 0.3);
    box-shadow: 0 8px 32px rgba(236, 72, 153, 0.15);
}

#detail-4 {
    grid-column: 5 / 13;
}
#detail-4:hover {
    border-color: rgba(245, 158, 11, 0.3);
    box-shadow: 0 8px 32px rgba(245, 158, 11, 0.15);
}

.detail-heading {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(0.8rem, 1vw, 0.9rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #8B7E72;
    margin-bottom: 1.25rem;
}

.detail-body {
    font-family: 'Crimson Text', Georgia, serif;
    color: #E8DFD0;
    text-align: justify;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.detail-body:last-child {
    margin-bottom: 0;
}

.detail-marginalia {
    font-style: italic;
    color: #8B7E72;
    font-size: 0.9em;
    border-left: 2px solid rgba(168, 85, 247, 0.3);
    padding-left: 1rem;
    margin-top: 0.5rem;
}

/* Detail entries */
.detail-entry {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(139, 126, 114, 0.15);
}

.detail-entry:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.entry-date {
    font-family: 'Crimson Text', Georgia, serif;
    font-style: italic;
    font-size: 0.85rem;
    color: #8B7E72;
    display: block;
    margin-bottom: 0.35rem;
}

.entry-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    font-weight: 700;
    color: #E8DFD0;
    margin-bottom: 0.5rem;
}

.entry-body {
    font-family: 'Crimson Text', Georgia, serif;
    color: #E8DFD0;
    text-align: justify;
    line-height: 1.7;
}

/* ========== FOCUS LIST ========== */
.focus-list {
    list-style: none;
}

.focus-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid rgba(139, 126, 114, 0.1);
    transition: transform 300ms ease;
}

.focus-item:last-child {
    border-bottom: none;
}

.focus-item:hover {
    transform: translateX(6px);
}

.focus-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.focus-item[data-accent="violet"] .focus-dot {
    background-color: #A855F7;
    box-shadow: 0 0 8px rgba(168, 85, 247, 0.5);
}
.focus-item[data-accent="blue"] .focus-dot {
    background-color: #3B82F6;
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.5);
}
.focus-item[data-accent="magenta"] .focus-dot {
    background-color: #EC4899;
    box-shadow: 0 0 8px rgba(236, 72, 153, 0.5);
}
.focus-item[data-accent="amber"] .focus-dot {
    background-color: #F59E0B;
    box-shadow: 0 0 8px rgba(245, 158, 11, 0.5);
}

.focus-text {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    color: #E8DFD0;
}

/* ========== STATUS ROW ========== */
#status-row {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(1.25rem, 3vw, 2.5rem);
    padding: clamp(1rem, 2vw, 1.5rem) 0;
    background-color: rgba(42, 31, 26, 0.5);
    border-radius: 8px;
}

.status-indicator {
    position: relative;
    width: 18px;
    height: 18px;
    border-radius: 50% 45% 55% 48%;
    cursor: pointer;
    transition: transform 300ms ease;
}

.status-indicator:hover {
    transform: scale(1.5);
}

.status-indicator:hover .status-tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.status-indicator[data-color="violet"] {
    background-color: #A855F7;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.4), 0 0 45px rgba(168, 85, 247, 0.15);
    animation: statusPulseViolet var(--pulse-rate, 3s) ease-in-out infinite;
}
.status-indicator[data-color="blue"] {
    background-color: #3B82F6;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.4), 0 0 45px rgba(59, 130, 246, 0.15);
    animation: statusPulseBlue var(--pulse-rate, 3s) ease-in-out infinite;
}
.status-indicator[data-color="magenta"] {
    background-color: #EC4899;
    box-shadow: 0 0 15px rgba(236, 72, 153, 0.4), 0 0 45px rgba(236, 72, 153, 0.15);
    animation: statusPulseMagenta var(--pulse-rate, 3s) ease-in-out infinite;
}
.status-indicator[data-color="amber"] {
    background-color: #F59E0B;
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.4), 0 0 45px rgba(245, 158, 11, 0.15);
    animation: statusPulseAmber var(--pulse-rate, 3s) ease-in-out infinite;
}

@keyframes statusPulseViolet {
    0%, 100% { transform: scale(1); box-shadow: 0 0 15px rgba(168, 85, 247, 0.4), 0 0 45px rgba(168, 85, 247, 0.15); }
    50% { transform: scale(1.15); box-shadow: 0 0 20px rgba(168, 85, 247, 0.6), 0 0 60px rgba(168, 85, 247, 0.25); }
}
@keyframes statusPulseBlue {
    0%, 100% { transform: scale(1); box-shadow: 0 0 15px rgba(59, 130, 246, 0.4), 0 0 45px rgba(59, 130, 246, 0.15); }
    50% { transform: scale(1.15); box-shadow: 0 0 20px rgba(59, 130, 246, 0.6), 0 0 60px rgba(59, 130, 246, 0.25); }
}
@keyframes statusPulseMagenta {
    0%, 100% { transform: scale(1); box-shadow: 0 0 15px rgba(236, 72, 153, 0.4), 0 0 45px rgba(236, 72, 153, 0.15); }
    50% { transform: scale(1.15); box-shadow: 0 0 20px rgba(236, 72, 153, 0.6), 0 0 60px rgba(236, 72, 153, 0.25); }
}
@keyframes statusPulseAmber {
    0%, 100% { transform: scale(1); box-shadow: 0 0 15px rgba(245, 158, 11, 0.4), 0 0 45px rgba(245, 158, 11, 0.15); }
    50% { transform: scale(1.15); box-shadow: 0 0 20px rgba(245, 158, 11, 0.6), 0 0 60px rgba(245, 158, 11, 0.25); }
}

.status-tooltip {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%) translateY(5px);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.7rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #E8DFD0;
    background-color: rgba(26, 20, 16, 0.9);
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 250ms ease, transform 250ms ease;
}

/* ========== FOOTER ========== */
#site-footer {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem clamp(1rem, 2vw, 1.5rem);
}

.footer-text {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.75rem;
    font-weight: 400;
    color: #8B7E72;
    letter-spacing: 0.1em;
}

.footer-blob {
    width: 40px;
    height: 40px;
    border-radius: 50% 40% 60% 45%;
    background: radial-gradient(circle at 40% 40%, #A855F7 0%, transparent 70%);
    opacity: 0.3;
    filter: blur(4px);
    animation: blobMorph 10s ease-in-out infinite alternate;
}

/* ========== BLOB TRAILS ========== */
.blob-trail {
    position: absolute;
    border-radius: inherit;
    background: inherit;
    filter: inherit;
    opacity: 0;
    pointer-events: none;
    animation: trailFade 800ms ease-out forwards;
    will-change: opacity;
}

@keyframes trailFade {
    0% { opacity: 0.5; }
    100% { opacity: 0; }
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
    #hero-panel {
        grid-column: 1 / -1;
        grid-row: 2 / 4;
        min-height: 280px;
    }

    #badge-grid {
        grid-column: 1 / -1;
        grid-row: 4 / 5;
    }

    #detail-1 {
        grid-column: 1 / -1;
    }

    #detail-2 {
        grid-column: 1 / -1;
    }

    #detail-3 {
        grid-column: 1 / 7;
    }

    #detail-4 {
        grid-column: 7 / 13;
    }
}

@media (max-width: 640px) {
    #dashboard {
        grid-template-columns: 1fr;
    }

    #hero-panel,
    #badge-grid,
    #detail-1,
    #detail-2,
    #detail-3,
    #detail-4,
    #status-row,
    #site-footer {
        grid-column: 1 / -1;
    }

    #badge-grid {
        grid-template-columns: 1fr 1fr;
    }

    .atmo-blob {
        opacity: 0.1;
    }
}
