/* =========================================================
   Talk to CEO — Public (employee) styles
   ========================================================= */
:root {
    --navy-900: #0a1f38;
    --navy-800: #0f2b4c;
    --navy-700: #173d66;
    --navy-100: #e7edf5;
    --gold-500: #c8a24a;
    --gold-100: #f8f1df;
    --ink: #1d2b3a;
    --ink-2: #4c5968;
    --muted: #8a94a3;
    --line: #e3e8ef;
    --bg: #f3f5f9;
    --surface: #ffffff;
    --radius: 16px;
    --shadow: 0 1px 2px rgba(15, 43, 76, .04), 0 8px 24px rgba(15, 43, 76, .06);
    --bs-primary: var(--navy-800);
    --bs-primary-rgb: 15, 43, 76;
    --bs-body-font-family: "IBM Plex Sans Thai", system-ui, -apple-system, "Segoe UI", sans-serif;
    --bs-link-color: var(--navy-700);
    --bs-link-color-rgb: 23, 61, 102;
}

body.public {
    background: var(--bg);
    color: var(--ink);
    font-family: var(--bs-body-font-family);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ---------- Header ---------- */
.site-header {
    background: var(--navy-900);
    color: #fff;
    padding: 14px 0;
    position: sticky;
    top: 0;
    z-index: 20;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .06);
}
.brand { display: flex; align-items: center; gap: 12px; color: #fff; text-decoration: none; }
.brand:hover { color: #fff; }
.brand-logo {
    width: 44px; height: 44px; flex: 0 0 auto;
    background: #fff; border-radius: 50%; padding: 2px;
    box-shadow: 0 0 0 2px rgba(200, 162, 74, .55);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 16px; }
.brand-text small { font-size: 12px; color: rgba(255, 255, 255, .65); }
.site-nav { display: flex; gap: 4px; }
.site-nav a {
    color: rgba(255, 255, 255, .75);
    text-decoration: none;
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 14px;
    display: flex; align-items: center; gap: 6px;
}
.site-nav a:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.site-nav a.active { color: #fff; background: rgba(255, 255, 255, .12); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    color: #fff;
    padding: 36px 0 92px;
    background:
        linear-gradient(115deg, rgba(10, 31, 56, .94) 0%, rgba(15, 43, 76, .86) 55%, rgba(23, 61, 102, .70) 100%),
        url("../images/talk_to_ceo.jpg") center / cover no-repeat,
        var(--navy-800);
}
.hero::after {
    content: "";
    position: absolute; inset: auto 0 0 0; height: 4px;
    background: linear-gradient(90deg, var(--gold-500), transparent 70%);
}
.hero .breadcrumb { --bs-breadcrumb-divider-color: rgba(255, 255, 255, .5); margin-bottom: 14px; font-size: 14px; }
.hero .breadcrumb a { color: rgba(255, 255, 255, .75); text-decoration: none; }
.hero .breadcrumb a:hover { color: #fff; }
.hero .breadcrumb-item.active { color: var(--gold-500); }
.hero h1 { font-weight: 700; font-size: clamp(28px, 4vw, 40px); margin-bottom: 8px; }
.hero .lead { color: rgba(255, 255, 255, .8); max-width: 680px; font-size: 17px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.hero-badges span {
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 13px;
    display: inline-flex; align-items: center; gap: 6px;
}
.hero-badges i { color: var(--gold-500); }

.main-wrap { margin-top: -60px; position: relative; z-index: 2; padding-bottom: 48px; flex: 1; }

/* ---------- Cards ---------- */
.ttc-card {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    background: var(--surface);
}
.card-header-ttc {
    display: flex; align-items: center; gap: 14px;
    padding: 22px 28px;
    border-bottom: 1px solid var(--line);
}
@media (min-width: 768px) { .card-header-ttc { padding: 26px 48px; } }
.icon-circle {
    width: 44px; height: 44px; flex: 0 0 44px;
    border-radius: 12px;
    background: var(--navy-100);
    color: var(--navy-800);
    display: grid; place-items: center;
    font-size: 20px;
}
.info-card { font-size: 14.5px; color: var(--ink-2); line-height: 1.75; }
.info-card h3 { color: var(--ink); display: flex; align-items: center; gap: 8px; }
.info-card h3 i { color: var(--gold-500); }
.notice-card { border-left: 4px solid #dc3545; }

/* ---------- Form ---------- */
.form-label { font-weight: 600; color: var(--ink); margin-bottom: 8px; }
.form-control, .form-select {
    border-color: #d5dce6;
    border-radius: 10px;
}
.form-control:focus, .form-select:focus {
    border-color: var(--navy-700);
    box-shadow: 0 0 0 .2rem rgba(15, 43, 76, .12);
}
textarea.form-control { line-height: 1.7; resize: vertical; min-height: 160px; }
.btn-primary {
    --bs-btn-bg: var(--navy-800);
    --bs-btn-border-color: var(--navy-800);
    --bs-btn-hover-bg: var(--navy-900);
    --bs-btn-hover-border-color: var(--navy-900);
    --bs-btn-active-bg: var(--navy-900);
    --bs-btn-disabled-bg: var(--navy-700);
    --bs-btn-disabled-border-color: var(--navy-700);
    border-radius: 10px;
    font-weight: 600;
}
.btn-outline-primary {
    --bs-btn-color: var(--navy-800);
    --bs-btn-border-color: var(--navy-800);
    --bs-btn-hover-bg: var(--navy-800);
    --bs-btn-hover-border-color: var(--navy-800);
}

.dropzone {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    border: 2px dashed #c7d0dc;
    border-radius: 12px;
    padding: 26px 16px;
    text-align: center;
    background: #fafbfd;
    cursor: pointer;
    transition: border-color .15s, background .15s;
    width: 100%;
}
.dropzone:hover, .dropzone.drag { border-color: var(--navy-700); background: var(--navy-100); }
.dropzone > i { font-size: 30px; color: var(--navy-700); }
.dz-title { font-weight: 500; color: var(--ink); }
.dz-hint { font-size: 13px; color: var(--muted); }
.dz-file {
    margin-top: 8px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 12px;
    font-size: 13px;
    display: inline-flex; align-items: center; gap: 8px;
}
.dz-file button { border: 0; background: none; color: #dc3545; padding: 0; line-height: 1; }
#attachfile:focus-visible + .dropzone, .dropzone:focus-within { outline: 2px solid var(--navy-700); }

.captcha-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.captcha-img {
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    background: #f6f8fb;
    line-height: 0;
}
.captcha-refresh { border: 1px solid var(--line); border-radius: 10px; }
.captcha-refresh i { display: inline-block; transition: transform .4s; }
.captcha-refresh.spin i { transform: rotate(360deg); }
.captcha-input { max-width: 240px; letter-spacing: .2em; text-transform: uppercase; font-weight: 600; }
.captcha-input::placeholder { letter-spacing: normal; text-transform: none; font-weight: 400; font-size: 15px; }

/* Honeypot (ซ่อนจากผู้ใช้จริง แต่ bot มองเห็น) */
.hp-field { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Success ---------- */
.success-card { border-top: 4px solid #198754; }
.success-icon {
    width: 64px; height: 64px; margin: 0 auto 16px;
    border-radius: 50%;
    background: #e8f5ee; color: #198754;
    display: grid; place-items: center; font-size: 34px;
}
.tracking-box {
    display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: center;
    background: var(--gold-100);
    border: 1px dashed var(--gold-500);
    border-radius: 12px;
    padding: 16px 20px;
}
.tracking-item { display: flex; flex-direction: column; text-align: center; }
.tracking-item span { font-size: 12px; color: var(--ink-2); }
.tracking-item strong { font-size: 20px; letter-spacing: .06em; color: var(--navy-900); font-variant-numeric: tabular-nums; }

/* ---------- Tracking result ---------- */
.status-badge {
    display: inline-flex; align-items: center; gap: 6px;
    border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 600;
}
.status-new { background: #e7eefb; color: #1f4f9a; }
.status-in_progress { background: #fff4dc; color: #8a5a00; }
.status-responded { background: #e3f4ea; color: #146c3a; }
.status-closed { background: #eceef1; color: #4c5968; }

.progress-steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; position: relative; }
.progress-steps li { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; position: relative; font-size: 13px; color: var(--muted); }
.progress-steps li::before {
    content: ""; position: absolute; top: 16px; left: -50%; width: 100%; height: 3px; background: var(--line); z-index: 0;
}
.progress-steps li:first-child::before { display: none; }
.progress-steps li.done::before, .progress-steps li.current::before { background: var(--navy-700); }
.progress-steps .dot {
    width: 34px; height: 34px; border-radius: 50%;
    display: grid; place-items: center;
    background: #fff; border: 2px solid var(--line); color: var(--muted);
    font-weight: 600; position: relative; z-index: 1;
}
.progress-steps li.done .dot { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }
.progress-steps li.current .dot { border-color: var(--navy-800); color: var(--navy-800); box-shadow: 0 0 0 4px rgba(15, 43, 76, .12); }
.progress-steps li.current .label, .progress-steps li.done .label { color: var(--ink); font-weight: 500; }

.empty-note { background: #f7f9fb; border-radius: 12px; padding: 16px 18px; color: var(--ink-2); }
.timeline { border-left: 2px solid var(--line); margin-left: 8px; padding-left: 20px; }
.timeline-item { position: relative; padding-bottom: 18px; }
.timeline-item::before {
    content: ""; position: absolute; left: -27px; top: 6px;
    width: 12px; height: 12px; border-radius: 50%;
    background: var(--gold-500); box-shadow: 0 0 0 3px #fff;
}
.timeline-date { font-size: 12.5px; color: var(--muted); margin-bottom: 4px; }
.timeline-body { background: #f7f9fb; border-radius: 12px; padding: 14px 16px; line-height: 1.7; }

/* ---------- Footer ---------- */
.site-footer { background: #fff; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; padding: 18px 0; }

@media (max-width: 575.98px) {
    .site-nav span { display: none; }
    .hero { padding-bottom: 80px; }
    .captcha-input { max-width: none; flex: 1 1 100%; }
    .progress-steps { font-size: 12px; }
}

.closed-icon {
    width: 64px; height: 64px; margin: 0 auto 16px;
    border-radius: 50%; background: var(--navy-100); color: var(--navy-700);
    display: grid; place-items: center; font-size: 32px;
}
