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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, sans-serif;
    color: #eef4ff;
    line-height: 1.5;
    min-height: 100vh;
    background: radial-gradient(circle at 20% 30%, #0a0f1f, #03050b);
    position: relative;
    padding: 2rem 1.5rem 3rem;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
    z-index: 0;
}

.tech-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.tech-glow .particle-line {
    position: absolute;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.4), rgba(100, 150, 255, 0.3), transparent);
    width: 100%;
    height: 2px;
    filter: blur(3px);
    animation: slideBeam 12s infinite linear;
    opacity: 0.5;
}

.tech-glow .particle-line:nth-child(1) { top: 15%; animation-duration: 18s; opacity: 0.4; width: 80%; left: -20%;}
.tech-glow .particle-line:nth-child(2) { top: 45%; animation-duration: 14s; animation-delay: -3s; width: 70%; left: -10%; background: linear-gradient(90deg, transparent, rgba(100, 200, 255, 0.5), transparent);}
.tech-glow .particle-line:nth-child(3) { top: 70%; animation-duration: 20s; animation-delay: -7s; width: 90%; left: -30%;}
.tech-glow .particle-line:nth-child(4) { top: 88%; animation-duration: 11s; animation-delay: -2s; width: 60%;}

@keyframes slideBeam {
    0% { transform: translateX(-100%) skewX(-15deg); opacity: 0; }
    10% { opacity: 0.7; }
    90% { opacity: 0.4; }
    100% { transform: translateX(150%) skewX(-15deg); opacity: 0; }
}

#starCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: auto;
    z-index: 1;
    display: block;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 10;
}

.hero {
    margin-bottom: 3rem;
    text-align: center;
    backdrop-filter: blur(2px);
}

[contenteditable="true"] {
    outline: none;
    transition: background 0.2s, box-shadow 0.1s;
    border-radius: 12px;
    padding: 0 4px;
}

[contenteditable="true"]:hover {
    background: rgba(80, 150, 255, 0.2);
    box-shadow: 0 0 0 2px rgba(80, 180, 255, 0.4);
    cursor: text;
}

[contenteditable="true"]:focus {
    background: rgba(30, 80, 150, 0.4);
    box-shadow: 0 0 0 2px #3b9eff;
}

.site-title {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #c0f2ff, #6c8eff, #3c6eff);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    display: inline-block;
    margin-bottom: 0.5rem;
    text-shadow: 0 0 12px rgba(60, 110, 255, 0.3);
}

.sub {
    font-size: 1rem;
    color: #9bb4ff;
    font-weight: 400;
    border-top: 1px solid rgba(64, 128, 255, 0.3);
    display: inline-block;
    padding-top: 0.75rem;
    margin-top: 0.5rem;
    letter-spacing: 1px;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 0.8rem;
    background: rgba(15, 25, 45, 0.45);
    backdrop-filter: blur(12px);
    padding: 0.6rem 1.2rem;
    border-radius: 60px;
    border: 1px solid rgba(72, 140, 255, 0.25);
}

.stats-bar {
    font-size: 0.85rem;
    color: #bfd6ff;
}

.stats-count {
    background: rgba(0, 20, 50, 0.7);
    padding: 0.3rem 0.9rem;
    border-radius: 40px;
    font-weight: 500;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(0, 200, 255, 0.3);
}

.admin-status {
    background: rgba(0, 10, 25, 0.6);
    padding: 0.3rem 1rem;
    border-radius: 40px;
    font-size: 0.8rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    backdrop-filter: blur(5px);
}

.admin-status button {
    background: none;
    border: none;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.75rem;
    padding: 0.2rem 0.6rem;
    border-radius: 30px;
    transition: 0.2s;
}

.login-btn { background: #2c5f8a; color: white; box-shadow: 0 0 6px #3c8eff; }
.logout-btn { background: #4e5b74; color: #eef; }
.admin-badge { background: linear-gradient(105deg, #2c5282, #1e3a5f); padding: 0.2rem 0.7rem; border-radius: 30px; color: #ccf0ff; font-size: 0.7rem; }

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 1.8rem;
    margin-top: 1rem;
}

.card {
    background: rgba(12, 22, 40, 0.65);
    backdrop-filter: blur(12px);
    border-radius: 28px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(0, 210, 255, 0.15);
    transition: all 0.35s cubic-bezier(0.2, 0, 0, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(0, 180, 230, 0.25);
    cursor: pointer;
    position: relative;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 35px -12px rgba(0, 150, 255, 0.35), 0 0 0 1.5px rgba(0, 210, 255, 0.5);
    background: rgba(20, 35, 60, 0.8);
}

.card-content {
    padding: 1.6rem 1.5rem 1.8rem;
    flex: 1;
}

.card-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: rgba(0, 120, 200, 0.2);
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 24px;
    transition: 0.2s;
    border: 1px solid rgba(0, 200, 250, 0.4);
}

.card-title {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0.8rem 0 0.5rem 0;
    letter-spacing: -0.3px;
    color: #eff3ff;
}

.card-desc {
    font-size: 0.85rem;
    color: #b5ceff;
    line-height: 1.45;
    margin-bottom: 1rem;
}

.card-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.7rem;
    font-weight: 500;
    color: #86afe0;
    margin-top: 0.75rem;
    border-top: 1px solid rgba(60, 140, 220, 0.4);
    padding-top: 0.75rem;
}

.admin-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
    z-index: 5;
    opacity: 0;
    transition: opacity 0.2s;
}
.card:hover .admin-actions { opacity: 1; }
.admin-actions button {
    background: rgba(0, 30, 60, 0.9);
    backdrop-filter: blur(8px);
    border: 1px solid #2f8eff;
    color: white;
    font-size: 0.7rem;
    padding: 0.3rem 0.7rem;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 500;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background: rgba(10, 20, 35, 0.7);
    backdrop-filter: blur(12px);
    border-radius: 48px;
    border: 1px solid rgba(0, 180, 255, 0.3);
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    z-index: 1000;
}
.modal-card {
    background: #0f172f;
    max-width: 480px;
    width: 90%;
    border-radius: 2rem;
    padding: 1.8rem;
    box-shadow: 0 0 20px rgba(0, 120, 255, 0.3);
    border: 1px solid #2c5a9e;
}
.modal-card h3 { font-size: 1.5rem; font-weight: 600; margin-bottom: 1.2rem; color: #b8e2ff; }
.input-group { margin-bottom: 1.2rem; display: flex; flex-direction: column; gap: 0.4rem; }
.input-group label { font-weight: 500; font-size: 0.8rem; color: #9ec0ff; }
.input-group input, .input-group textarea {
    padding: 0.8rem 1rem;
    border: 1px solid #2f6190;
    border-radius: 1rem;
    background: #030b17;
    color: #eef5ff;
    font-family: inherit;
}
.modal-actions button { padding: 0.6rem 1.2rem; border-radius: 2rem; border: none; font-weight: 500; cursor: pointer; }
.btn-cancel { background: #2a3b55; color: #cde2ff; }
.btn-confirm { background: #2c6ea0; color: white; }

.footer-icp {
    text-align: center;
    margin-top: 4rem;
    padding: 1.2rem 1rem;
    border-top: 1px solid rgba(0, 180, 255, 0.3);
    font-size: 0.75rem;
    color: #87b0e0;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(4px);
    border-radius: 40px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}
.footer-icp a { color: #8bbdff; text-decoration: none; }

.admin-float {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 102;
    display: none;
}
.admin-btn {
    background: rgba(0, 90, 150, 0.9);
    backdrop-filter: blur(10px);
    color: white;
    border: 1px solid #2a9eff;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.4rem;
    border-radius: 60px;
    font-weight: 500;
    cursor: pointer;
    box-shadow: 0 0 14px rgba(0, 160, 255, 0.4);
}
.toast-feedback {
    position: fixed;
    bottom: 5rem;
    left: 50%;
    transform: translateX(-50%);
    background: #0e1b2f;
    backdrop-filter: blur(12px);
    border: 1px solid #2c8eff;
    color: #dcf0ff;
    padding: 0.6rem 1.2rem;
    border-radius: 40px;
    z-index: 1100;
    font-size: 0.85rem;
    white-space: nowrap;
}
@media (max-width: 640px) { body { padding: 1rem; } .admin-actions { opacity: 0.9; } .footer-icp { width: 100%; } }