/* Admin panel — reuses the tokens from site.css */
body.admin{background:#eef3f8;display:flex;min-height:100vh}
.sidebar{width:250px;flex:none;background:linear-gradient(180deg,var(--navy),var(--blue-dark));color:#fff;padding:18px 0;position:sticky;top:0;height:100vh;overflow:auto}
.side-brand{display:flex;align-items:center;gap:12px;padding:0 20px 18px;border-bottom:1px solid rgba(255,255,255,.15);font-family:"Poppins",sans-serif;font-weight:600}
.side-brand img{width:52px;height:52px;background:#fff;border-radius:12px;padding:3px;object-fit:contain}
.sidebar nav{display:grid;padding:14px 10px;gap:4px}
.sidebar nav a{color:#d6e5f6;padding:11px 14px;border-radius:10px;font-size:.94rem;font-weight:500;transition:background .2s,transform .2s}
.sidebar nav a:hover{background:rgba(255,255,255,.12);text-decoration:none;transform:translateX(4px)}
.admin-main{flex:1;min-width:0;display:flex;flex-direction:column}
.admin-top{background:#fff;padding:14px 26px;display:flex;align-items:center;gap:14px;box-shadow:0 2px 10px rgba(12,47,87,.08);position:sticky;top:0;z-index:20}
.admin-top strong{font-family:"Poppins",sans-serif;font-size:1.1rem;color:var(--navy)}
.admin-user{margin-left:auto;display:flex;align-items:center;gap:16px;font-size:.9rem;color:var(--soft)}
.btn-link{background:none;border:0;color:var(--pink);font-weight:600;cursor:pointer;font:inherit;font-weight:600}
.side-toggle{display:none}.side-burger{display:none;font-size:1.5rem;cursor:pointer;color:var(--navy)}
.admin-content{padding:26px;animation:rise .5s ease both}
.panel{background:#fff;border-radius:var(--radius);padding:24px;box-shadow:var(--shadow);margin-bottom:22px}
.panel.narrow{max-width:520px}
.panel h2{font-size:1.15rem}
.panel-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}
.panel-head h2{margin:0}
.hint{font-size:.9rem}
.two-col{display:grid;grid-template-columns:1fr 1fr;gap:22px;align-items:start}
.mt{margin-top:14px}

.kpi-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:16px;margin-bottom:22px}
.kpi{border-radius:var(--radius);padding:22px;color:#fff;display:block}
.kpi:hover{transform:translateY(-4px);text-decoration:none}
.kpi strong{display:block;font-family:"Poppins",sans-serif;font-size:2.2rem;line-height:1}
.kpi span{font-size:.88rem;opacity:.95}
.kpi-blue{background:linear-gradient(135deg,var(--blue),var(--blue-dark))}
.kpi-red{background:linear-gradient(135deg,var(--pink),var(--pink-dark))}
.kpi-green{background:linear-gradient(135deg,var(--green),#55801f)}
.kpi-gold{background:linear-gradient(135deg,var(--gold),var(--gold-dark));color:#1b2433}
.kpi-navy{background:linear-gradient(135deg,#2a4a75,var(--navy))}

.table-wrap{overflow-x:auto}
.data-table{width:100%;border-collapse:collapse;font-size:.92rem}
.data-table th{text-align:left;background:#eef4fa;color:var(--navy);padding:11px 12px;font-family:"Poppins",sans-serif;font-size:.82rem;white-space:nowrap}
.data-table td{padding:11px 12px;border-bottom:1px solid var(--line);vertical-align:middle}
.data-table tr:hover td{background:#f8fbfe}
.empty{text-align:center;color:var(--soft);padding:24px!important}
.actions{display:flex;gap:6px;align-items:center;white-space:nowrap}
.actions form{margin:0}
.badge{display:inline-block;padding:3px 10px;border-radius:999px;font-size:.76rem;font-weight:700}
.b-new{background:#fde8ed;color:var(--pink-dark)}
.b-contacted{background:#fff1d6;color:#a86400}
.b-closed{background:#e8f4d8;color:#3f6a12}
.btn-sm{padding:6px 12px;font-size:.82rem;border-radius:8px;background:var(--blue);color:#fff}
.btn-sm:hover{background:var(--blue-dark);color:#fff}
.btn-danger{background:var(--pink);color:#fff}.btn-danger:hover{background:var(--pink-dark);color:#fff}
.btn-light{background:#eef4fa;color:var(--navy)}.btn-light:hover{background:#dfeaf5}
.filter-bar{display:flex;gap:10px;flex-wrap:wrap;margin-bottom:16px}
.filter-bar input,.filter-bar select{padding:10px 12px;border:1.5px solid var(--line);border-radius:10px;font:inherit}
.filter-bar input{flex:1;min-width:200px}
.detail-list{display:grid;grid-template-columns:130px 1fr;gap:10px 14px;margin:0}
.detail-list dt{color:var(--soft);font-weight:600;font-size:.9rem}.detail-list dd{margin:0;word-break:break-word}

.upload-form{display:flex;gap:14px;align-items:end;flex-wrap:wrap}
.upload-form .field{margin:0;flex:1;min-width:190px}.upload-form .field.small{flex:0 0 90px;min-width:90px}
.slide-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:18px}
.slide-card{background:#fff;border-radius:var(--radius);overflow:hidden;box-shadow:var(--shadow);transition:transform .25s}
.slide-card:hover{transform:translateY(-4px)}
.slide-card img{width:100%;height:150px;object-fit:cover;background:var(--navy)}
.slide-card.off img{filter:grayscale(1) opacity(.55)}
.slide-meta{padding:14px;display:grid;gap:8px}

/* login */
.login-page{min-height:100vh;display:flex;align-items:center;justify-content:center;background:radial-gradient(circle at 20% 10%,#2b7fc9,var(--blue-dark) 45%,var(--navy));padding:20px}
.login-card{background:#fff;border-radius:20px;padding:34px;width:100%;max-width:400px;box-shadow:0 30px 60px -20px rgba(0,0,0,.5);border-top:6px solid var(--gold);text-align:center;animation:rise .7s cubic-bezier(.2,.7,.2,1) both}
.login-card img{width:96px;height:96px;object-fit:contain;margin:0 auto 8px}
.login-card h1{font-size:1.5rem;margin-bottom:4px}
.login-card .field{text-align:left}
.back-link{display:inline-block;margin-top:16px;font-size:.9rem}

@media(max-width:1100px){.kpi-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:900px){
  .two-col{grid-template-columns:1fr}
  .sidebar{position:fixed;left:-260px;z-index:60;transition:left .3s}
  .side-toggle:checked~.sidebar{left:0}
  .side-burger{display:block}
  .kpi-grid{grid-template-columns:repeat(2,1fr)}
}
.kpi-teal {
   background-color: #0d9488;   /* match how your other kpi-* colors are applied */
}
.kpi-teal strong {
    color: #fff;
}
.kpi .kpi-link {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    font-weight: 600;
    opacity: .75;
    transition: opacity .2s, transform .2s;
}
.kpi:hover .kpi-link {
    opacity: 1;
    transform: translateX(3px);
}
.g-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
    .g-head h2 { margin: 0; }
    .g-add { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 24px; align-items: start; }
    @media (max-width: 800px) { .g-add { grid-template-columns: 1fr; } }

    .g-drop { border: 2px dashed #9fb3bd; border-radius: 14px; background: #f7fafb; min-height: 280px;
              display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
              padding: 18px; cursor: pointer; transition: border-color .2s, background .2s; position: relative; overflow: hidden; }
    .g-drop:hover, .g-drop.drag { border-color: #0d9488; background: #effaf8; }
    .g-drop.has-file { border-style: solid; border-color: #0d9488; background: #000; padding: 0; cursor: default; }
    .g-drop input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
    .g-drop-icon { font-size: 40px; margin-bottom: 6px; }
    .g-drop-main { font-weight: 700; color: #1a2b33; }
    .g-drop-hint { color: #667; font-size: 13px; margin-top: 4px; }

    .g-preview { width: 100%; display: none; }
    .g-drop.has-file .g-preview { display: block; }
    .g-drop.has-file .g-drop-empty { display: none; }
    .g-preview img, .g-preview video { width: 100%; max-height: 420px; object-fit: contain; display: block; background: #000; }
    .g-file-bar { display: none; align-items: center; justify-content: space-between; gap: 10px; background: #0d1f26; color: #fff; padding: 8px 12px; font-size: 13px; width: 100%; }
    .g-drop.has-file .g-file-bar { display: flex; }
    .g-file-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .g-change { background: #fff; color: #0d4a44; border: 0; border-radius: 6px; padding: 5px 12px; font-weight: 600; cursor: pointer; flex: none; }

    .g-error { color: #b3261e; font-size: 13.5px; margin-top: 8px; min-height: 18px; }
    .g-fields .field { margin-bottom: 14px; }
    .g-fields textarea { width: 100%; min-height: 110px; resize: vertical; font: inherit; padding: 10px; border: 1px solid #cfd8dc; border-radius: 8px; box-sizing: border-box; }
    .g-opt { color: #889; font-weight: 400; font-size: 12.5px; }
    .g-actions { display: flex; gap: 10px; margin-top: 6px; }

.field-name{
    color: #000 !important;
    font-size: 16px !important;
    font-weight: 800 !important;

}
    .g-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
    .g-head h2 { margin: 0; }
    .g-count { color: #667; font-size: 14px; margin-top: 2px; }
    .slide-card video { width: 100%; display: block; background: #000; aspect-ratio: 16 / 10; object-fit: cover; }
    .slide-card img   { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; display: block; }
    .type-chip { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: #e6f6f4; color: #0d7a70; margin-right: 6px; }
    .type-chip.video { background: #fdeee6; color: #b4531a; }
    .g-sub { display: block; color: #667; font-size: 13px; margin: 2px 0 6px; }
    .g-untitled { color: #99a; font-style: italic; font-weight: 400; }

    .album-section {
        margin: 24px 0 30px;
    }

    .album-section-heading {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        flex-wrap: wrap;
        margin-bottom: 16px;
    }

    .album-section-heading h3 {
        margin: 0;
        font-size: 20px;
        font-weight: 700;
    }

    .album-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 18px;
    }

    .album-card {
        display: block;
        min-width: 0;
        padding: 20px;
        border: 1px solid #e5e7eb;
        border-radius: 16px;
        background: var(--avk-surface, #fff);
        color: inherit;
        text-decoration: none;
        transition: transform .2s ease, box-shadow .2s ease,
                    border-color .2s ease;
    }

    .album-card:hover {
        transform: translateY(-3px);
        border-color: #94a3b8;
        box-shadow: 0 10px 26px rgba(15, 23, 42, .09);
        color: inherit;
        text-decoration: none;
    }

    .album-card.selected {
        border-color: #2563eb;
        box-shadow: 0 0 0 2px rgba(37, 99, 235, .12);
    }

    .album-icon {
        display: grid;
        place-items: center;
        width: 48px;
        height: 48px;
        margin-bottom: 14px;
        border-radius: 13px;
        background: #eff6ff;
        font-size: 25px;
    }

    .album-title {
        display: block;
        margin-bottom: 7px;
        font-weight: 700;
        overflow-wrap: anywhere;
    }

    .album-description {
        display: block;
        min-height: 38px;
        color: #64748b;
        font-size: 13px;
        overflow-wrap: anywhere;
    }

    .album-stats {
        display: flex;
        flex-wrap: wrap;
        gap: 7px;
        margin-top: 14px;
    }

    .album-stat {
        padding: 5px 9px;
        border-radius: 20px;
        background: #f1f5f9;
        color: #334155;
        font-size: 12px;
    }

    .album-open {
        display: block;
        margin-top: 15px;
        color: #2563eb;
        font-size: 13px;
        font-weight: 600;
    }

    .gallery-subheading {
        margin: 28px 0 15px;
        font-size: 19px;
        font-weight: 700;
    }

    .gallery-empty {
        grid-column: 1 / -1;
        padding: 28px 18px;
        border: 1px dashed #cbd5e1;
        border-radius: 14px;
        color: #64748b;
        text-align: center;
    }

    .gallery-album-label {
        display: inline-block;
        margin-top: 7px;
        padding: 4px 8px;
        border-radius: 7px;
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 12px;
    }
        .album-cover,
    .album-cover-placeholder {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        height: 170px;
        margin-bottom: 15px;
        border-radius: 12px;
        object-fit: cover;
        background: #eff6ff;
    }

    .album-cover-placeholder {
        font-size: 42px;
    }

    @media (max-width: 600px) {
        .album-grid {
            grid-template-columns: 1fr;
        }
    }

