/* =========================================================
   ORISH AGENCY — BỘ NHẬN DIỆN (PHIÊN BẢN TỐI / DARK)
   Building Beauty Brands · Premium · Elegant
   >>> ĐỔI MÀU TẠI ĐÂY nếu cần (sửa các biến --* bên dưới) <<<
   ========================================================= */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700&family=Montserrat:wght@300;400;500;600;700&display=swap');

:root {
    /* --- Bảng màu gốc Orish --- */
    --plum:        #5A2E4D;  /* Tím plum thương hiệu */
    --plum-soft:   #8a5a7c;  /* Plum nhạt */
    --beige:       #DCC5B6;  /* Be - dùng làm điểm nhấn vàng trên nền tối */
    --beige-bright:#ECDccF;  /* Be sáng (hover) */
    --cream:       #F2E9E3;  /* Kem - chữ chính */
    --mocha:       #B89A8C;  /* Nâu mocha (sáng lên cho nền tối) */

    /* --- Nền tối --- */
    --bg:          #1E171C;  /* Nền chính: tím-đen sâu */
    --surface:     #29202A;  /* Thẻ card */
    --surface-2:   #322735;  /* Card nổi / header */

    /* --- Vai trò giao diện --- */
    --primary:     var(--beige);     /* Nút chính: be vàng */
    --primary-hover: var(--beige-bright);
    --on-primary:  #2B2030;          /* Chữ trên nút be */
    --accent:      var(--beige);
    --text:        var(--cream);
    --text-muted:  #A99CA3;
    --line:        rgba(220,197,182,.16);
    --danger:      #d96b6b;
    --success:     #6cc08a;

    --radius: 16px;
    --shadow: 0 14px 44px rgba(0,0,0,.45);
    --shadow-sm: 0 6px 20px rgba(0,0,0,.30);

    --font-head: 'Playfair Display', Georgia, serif;
    --font-body: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--font-body);
    background:
        linear-gradient(rgba(30,23,28,.72), rgba(30,23,28,.82)),
        url('../img/spa-bg.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
    font-weight: 400;
}

h1, h2, h3, h4 { font-family: var(--font-head); font-weight: 600; letter-spacing: .2px; }
a { color: var(--beige); text-decoration: none; }
a:hover { color: var(--beige-bright); }

/* ---------- Logo lockup ---------- */
.brand { display: flex; align-items: center; gap: 12px; color: var(--cream); }
.brand-mark { color: var(--beige); font-size: 1.1rem; line-height: 1; }
.brand-name {
    font-family: var(--font-head); font-weight: 700; font-size: 1.5rem;
    letter-spacing: 4px; color: var(--cream); line-height: 1; display: flex; flex-direction: column;
}
.brand-name small {
    font-family: var(--font-body); font-weight: 500; font-size: .58rem;
    letter-spacing: 5px; color: var(--beige); margin-top: 3px;
}

/* ---------- Header ---------- */
.topbar {
    display: flex; align-items: center; justify-content: space-between;
    padding: 16px 32px;
    background: var(--surface-2);
    border-bottom: 1px solid var(--line);
    position: sticky; top: 0; z-index: 50;
    box-shadow: var(--shadow-sm);
}
.nav { display: flex; align-items: center; gap: 16px; }
.nav .who { color: var(--text-muted); font-size: .88rem; }
.nav .who b { color: var(--cream); font-weight: 600; }
.role-pill {
    font-size: .68rem; padding: 3px 11px; border-radius: 999px; font-weight: 600;
    background: rgba(220,197,182,.12); color: var(--beige);
    border: 1px solid rgba(220,197,182,.3); margin-left: 6px; letter-spacing: .5px;
}

/* ---------- Layout ---------- */
.container { max-width: 1120px; margin: 0 auto; padding: 40px 24px 72px; }
.page-title { font-size: 2rem; margin: 0 0 6px; color: var(--cream); }
.page-sub { color: var(--text-muted); margin: 0 0 32px; font-size: .98rem; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 11px 22px; border-radius: 999px; border: none; cursor: pointer;
    font-family: var(--font-body); font-weight: 600; font-size: .92rem; letter-spacing: .3px;
    background: var(--primary); color: var(--on-primary);
    transition: transform .06s ease, background .2s ease, box-shadow .2s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,.35);
}
.btn:hover { background: var(--primary-hover); color: var(--on-primary); box-shadow: 0 6px 22px rgba(0,0,0,.45); }
.btn:active { transform: translateY(1px); }
.btn.ghost { background: transparent; color: var(--beige); border: 1.5px solid rgba(220,197,182,.4); box-shadow: none; }
.btn.ghost:hover { border-color: var(--beige); background: rgba(220,197,182,.08); color: var(--beige-bright); }
.btn.danger { background: var(--danger); color: #2a1414; box-shadow: none; }
.btn.danger:hover { background: #e88585; color: #2a1414; }
.btn.sm { padding: 7px 15px; font-size: .8rem; }

/* ---------- Folder grid ---------- */
.grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.folder-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius); padding: 28px;
    box-shadow: var(--shadow-sm); transition: border-color .2s, transform .18s, box-shadow .2s;
    display: flex; flex-direction: column; gap: 16px; min-height: 180px;
    position: relative; overflow: hidden;
}
.folder-card::after {
    content: '✦'; position: absolute; top: 18px; right: 20px;
    color: var(--beige); font-size: 1rem; opacity: .5;
}
.folder-card:hover { border-color: rgba(220,197,182,.45); transform: translateY(-4px); box-shadow: var(--shadow); }
.folder-icon {
    width: 56px; height: 56px; border-radius: 14px;
    display: grid; place-items: center; font-size: 1.7rem;
    background: linear-gradient(145deg, var(--surface-2), var(--plum));
    border: 1px solid var(--line);
}
.folder-card h3 { margin: 0; font-size: 1.25rem; color: var(--cream); }
.folder-card .count { color: var(--text-muted); font-size: .86rem; margin-top: auto; font-weight: 500; }

/* ---------- Media grid ---------- */
.media-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(265px, 1fr)); }
.media-card {
    background: var(--surface); border-radius: var(--radius);
    overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-sm);
    display: flex; flex-direction: column; transition: transform .15s, box-shadow .2s;
}
.media-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.media-thumb { background: #000; aspect-ratio: 16/10; width: 100%; object-fit: cover; display: block; }
.media-thumb video, .media-thumb img { width: 100%; height: 100%; object-fit: cover; }
.media-body { padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; }
.media-body h4 { margin: 0; font-size: 1.08rem; color: var(--cream); }
.media-body p { margin: 0; color: var(--text-muted); font-size: .85rem; }
.media-meta { display:flex; justify-content: space-between; align-items:center; margin-top: 8px; font-size: .74rem; color: var(--text-muted); }
.tag { font-size: .66rem; text-transform: uppercase; letter-spacing: 1px; padding: 3px 9px; border-radius: 999px; background: rgba(184,154,140,.18); color: var(--mocha); font-weight: 600; }

/* ---------- Forms / cards ---------- */
.card {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow-sm);
}
.form-row { margin-bottom: 20px; }
label { display: block; margin-bottom: 7px; font-size: .86rem; color: var(--text-muted); font-weight: 500; }
input, select, textarea {
    width: 100%; padding: 12px 14px; border-radius: 12px;
    background: var(--bg); color: var(--cream);
    border: 1.5px solid var(--line); font-size: .95rem; font-family: var(--font-body);
    transition: border-color .15s, background .15s;
}
input::placeholder, textarea::placeholder { color: #7d7178; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--beige); background: var(--surface-2); }
select option { background: var(--surface); color: var(--cream); }
textarea { min-height: 90px; resize: vertical; }

/* ---------- Login ---------- */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 20px;
    background:
        linear-gradient(120deg, rgba(30,23,28,.92) 0%, rgba(90,46,77,.78) 55%, rgba(43,33,38,.85) 100%),
        url('../img/spa-bg.jpg');
    background-size: cover; background-position: center; }
.login-box .card { background: rgba(41,32,42,.82); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border: 1px solid rgba(220,197,182,.22); }
.login-box { width: 100%; max-width: 410px; }
.login-logo { text-align: center; margin-bottom: 6px; }
.login-logo .lg-mark { color: var(--beige); font-size: 1.3rem; }
.login-logo .lg-name { font-family: var(--font-head); font-weight: 700; font-size: 2.4rem; letter-spacing: 8px; color: var(--cream); margin: 4px 0 2px; }
.login-logo .lg-sub { font-weight: 500; font-size: .62rem; letter-spacing: 6px; color: var(--beige); }
.login-box .tagline { text-align: center; color: var(--mocha); margin: 14px 0 26px; font-family: var(--font-head); font-style: italic; font-size: 1.05rem; }
.login-foot { text-align:center; margin-top: 20px; font-size: .76rem; color: var(--text-muted); letter-spacing: 1px; }

/* ---------- Table ---------- */
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 13px 10px; border-bottom: 1px solid var(--line); font-size: .9rem; }
th { color: var(--text-muted); font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .5px; }

/* ---------- Flash ---------- */
.flash { padding: 13px 18px; border-radius: 12px; margin-bottom: 20px; font-size: .9rem; font-weight: 500; }
.flash.error { background: rgba(217,107,107,.12); border: 1px solid rgba(217,107,107,.4); color: #f0a9a9; }
.flash.success { background: rgba(108,192,138,.12); border: 1px solid rgba(108,192,138,.4); color: #a5e3bd; }

.empty { text-align: center; color: var(--text-muted); padding: 70px 20px; }
.empty p { margin-bottom: 18px; }
.inline { display: inline; }
.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 26px; gap: 12px; flex-wrap: wrap; }
.back-link { color: var(--text-muted); font-size: .88rem; font-weight: 500; }
.back-link:hover { color: var(--beige); }
