:root {
  --ink: #17262b;
  --muted: #65767a;
  --teal: #087e80;
  --teal-dark: #045d61;
  --mint: #dff5f0;
  --line: #dfe9e7;
  --paper: #ffffff;
  --warm: #fff5e8;
  --danger: #b43b4c;
  font-family: Inter, Manrope, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
[hidden] { display: none !important; }
.public-body { min-height: 100vh; background: linear-gradient(145deg, #ecf8f5, #f7fbfa 56%, #e6f4f2); }
.feedback-page { width: min(1120px, calc(100% - 32px)); margin: 0 auto; padding: 54px 0; display: grid; grid-template-columns: .84fr 1.16fr; gap: clamp(34px, 6vw, 82px); align-items: start; }
.feedback-intro { padding: 28px 0; position: sticky; top: 20px; }
.feedback-brand { display: inline-flex; color: var(--teal-dark); font-size: 22px; font-weight: 850; letter-spacing: -.04em; text-decoration: none; }
.feedback-brand.dark { color: var(--ink); }
.feedback-brand small { margin-left: 7px; color: var(--muted); font-size: 10px; letter-spacing: .08em; align-self: center; }
.feedback-eyebrow { margin: 42px 0 12px; color: var(--teal); font-size: 11px; font-weight: 850; letter-spacing: .18em; }
.feedback-intro h1, .login-card h1, .admin-hero h1 { margin: 0; font-size: clamp(36px, 5vw, 60px); line-height: 1.03; letter-spacing: -.055em; }
.feedback-intro > p:not(.feedback-eyebrow), .login-card > p:not(.feedback-eyebrow), .admin-hero p { color: var(--muted); font-size: 16px; line-height: 1.65; }
.feedback-trust { margin-top: 28px; padding: 16px 18px; display: flex; gap: 12px; border: 1px solid #c6e3dc; border-radius: 14px; background: rgba(255,255,255,.58); color: #315f5c; font-size: 13px; line-height: 1.5; }
.feedback-trust span { width: 24px; height: 24px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; background: var(--teal); color: white; }
.feedback-card, .login-card { border: 1px solid rgba(12, 90, 88, .12); border-radius: 26px; background: rgba(255,255,255,.94); box-shadow: 0 24px 75px rgba(29, 87, 84, .13); }
.feedback-card { padding: clamp(24px, 4vw, 44px); }
form { display: grid; gap: 20px; }
label { display: grid; gap: 8px; font-size: 13px; font-weight: 750; }
input, select, textarea { width: 100%; border: 1px solid #cbdad7; border-radius: 12px; background: white; color: var(--ink); outline: none; transition: border .18s, box-shadow .18s; }
input, select { min-height: 50px; padding: 0 14px; }
textarea { padding: 14px; resize: vertical; line-height: 1.55; }
input:focus, select:focus, textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 4px rgba(8, 126, 128, .11); }
label small { color: var(--muted); font-weight: 500; line-height: 1.4; }
.feedback-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.training-date { padding: 16px; border-radius: 14px; background: var(--warm); border: 1px solid #f3d6ad; }
.counter { justify-self: end; margin-top: -5px; }
.consent-row { grid-template-columns: auto 1fr; align-items: start; font-weight: 500; line-height: 1.45; }
.consent-row input { width: 20px; min-height: 20px; margin-top: 1px; accent-color: var(--teal); }
.consent-row a { color: var(--teal-dark); }
.honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.feedback-submit { min-height: 54px; border: 0; border-radius: 13px; background: linear-gradient(135deg, var(--teal-dark), var(--teal)); color: white; font-weight: 820; box-shadow: 0 12px 24px rgba(7, 106, 105, .2); }
.feedback-submit:hover { filter: brightness(1.05); }
.feedback-submit:disabled { opacity: .55; cursor: wait; }
.form-message { padding: 13px 15px; border-radius: 10px; font-size: 13px; line-height: 1.45; }
.form-message.error { border: 1px solid #f0bdc4; background: #fff0f2; color: var(--danger); }
.feedback-success { padding: 36px 10px; text-align: center; }
.feedback-success > span { width: 62px; height: 62px; margin: 0 auto 20px; display: grid; place-items: center; border-radius: 50%; background: var(--mint); color: var(--teal); font-size: 30px; }
.feedback-success h2 { margin: 0; font-size: 30px; }
.feedback-success p { color: var(--muted); line-height: 1.6; }
.feedback-success button { padding: 12px 16px; border: 1px solid var(--teal); border-radius: 10px; background: white; color: var(--teal-dark); font-weight: 750; }

.admin-body { min-height: 100vh; background: #f3f7f6; }
.login-page { min-height: 100vh; padding: 30px; display: grid; place-items: center; background: radial-gradient(circle at top left, #d5f1eb, transparent 42%), #edf6f4; }
.login-card { width: min(460px, 100%); padding: 40px; }
.login-card .feedback-eyebrow { margin-top: 34px; }
.login-card h1 { font-size: 42px; }
.login-card form { margin-top: 28px; }
.admin-header { min-height: 76px; padding: 0 clamp(20px, 5vw, 70px); display: flex; align-items: center; gap: 36px; border-bottom: 1px solid var(--line); background: white; }
.admin-header nav { display: flex; gap: 24px; flex: 1; }
.admin-header nav a { color: var(--muted); text-decoration: none; font-size: 13px; font-weight: 750; }
.admin-header nav a.active { color: var(--teal-dark); }
.admin-header form { display: block; }
.admin-header form button { padding: 9px 14px; border: 1px solid var(--line); border-radius: 9px; background: white; color: var(--muted); }
.admin-main { width: min(1220px, calc(100% - 36px)); margin: 0 auto; padding: 44px 0 80px; }
.admin-hero { display: flex; justify-content: space-between; align-items: end; gap: 32px; }
.admin-hero .feedback-eyebrow { margin-top: 0; }
.admin-hero h1 { font-size: clamp(40px, 5vw, 58px); }
.admin-stat { min-width: 170px; padding: 20px; display: grid; border-radius: 18px; background: var(--teal-dark); color: white; }
.admin-stat strong { font-size: 34px; }
.admin-stat span { color: rgba(255,255,255,.72); font-size: 12px; }
.admin-statuses { margin: 30px 0 18px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.admin-statuses button { padding: 17px 20px; display: flex; align-items: baseline; gap: 10px; border: 1px solid var(--line); border-radius: 14px; background: white; text-align: left; }
.admin-statuses strong { font-size: 24px; }
.admin-statuses span { color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-filters { padding: 14px; display: grid; grid-template-columns: 1.4fr 1fr .7fr auto; gap: 10px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.admin-filters button { padding: 0 18px; border: 1px solid var(--line); border-radius: 10px; background: #f7f9f9; color: var(--muted); }
.complaints-list { margin-top: 22px; display: grid; gap: 16px; }
.complaint-card { overflow: hidden; border: 1px solid var(--line); border-left: 5px solid #89a3a2; border-radius: 18px; background: white; box-shadow: 0 10px 32px rgba(43, 78, 75, .06); }
.complaint-card.status-new { border-left-color: #f0a93f; }
.complaint-card.status-in_progress { border-left-color: #4f82e8; }
.complaint-card.status-resolved { border-left-color: #27a26a; }
.complaint-card > header { padding: 18px 22px; display: flex; justify-content: space-between; gap: 16px; border-bottom: 1px solid #edf2f1; }
.complaint-card time { color: var(--muted); font-size: 12px; }
.complaint-badges { display: flex; flex-wrap: wrap; gap: 7px; }
.complaint-badges span { padding: 6px 9px; border-radius: 999px; font-size: 11px; font-weight: 750; }
.category-badge { background: var(--mint); color: var(--teal-dark); }
.status-badge { background: #edf1f4; color: #536369; }
.complaint-person { padding: 20px 22px; display: flex; flex-wrap: wrap; gap: 28px 50px; }
.complaint-person div { display: grid; gap: 5px; }
.complaint-person small, .complaint-message small { color: #8a999b; font-size: 9px; font-weight: 850; letter-spacing: .13em; }
.complaint-person a { color: var(--teal-dark); font-weight: 750; }
.complaint-message { margin: 0 22px; padding: 18px; border-radius: 12px; background: #f7faf9; }
.complaint-message p { margin: 8px 0 0; line-height: 1.65; }
.complaint-management { margin-top: 20px; padding: 18px 22px; display: grid; grid-template-columns: 220px 1fr auto; gap: 12px; align-items: end; background: #fbfcfc; border-top: 1px solid #edf2f1; }
.complaint-management label { font-size: 11px; }
.complaint-management textarea { min-height: 50px; }
.complaint-management button { min-height: 50px; padding: 0 16px; border: 0; border-radius: 10px; background: var(--teal); color: white; font-weight: 750; }
.save-result { color: #27865d; font-size: 11px; font-weight: 750; grid-column: 3; }
.admin-empty { margin-top: 22px; padding: 50px; display: grid; gap: 8px; place-items: center; border: 1px dashed #cbd8d6; border-radius: 18px; color: var(--muted); }

@media (max-width: 820px) {
  .feedback-page { grid-template-columns: 1fr; padding: 24px 0; }
  .feedback-intro { position: static; padding-bottom: 0; }
  .feedback-eyebrow { margin-top: 30px; }
  .admin-header { padding: 16px 20px; flex-wrap: wrap; gap: 14px; }
  .admin-header nav { order: 3; flex-basis: 100%; }
  .admin-hero { align-items: stretch; flex-direction: column; }
  .admin-stat { min-width: 0; }
  .admin-filters { grid-template-columns: 1fr 1fr; }
  .admin-filters input { grid-column: 1 / -1; }
  .complaint-management { grid-template-columns: 1fr; }
  .save-result { grid-column: 1; }
}
@media (max-width: 540px) {
  .feedback-page { width: min(100% - 20px, 1120px); }
  .feedback-card, .login-card { padding: 22px; border-radius: 18px; }
  .feedback-grid, .admin-statuses, .admin-filters { grid-template-columns: 1fr; }
  .admin-main { width: min(100% - 20px, 1220px); padding-top: 28px; }
  .complaint-card > header { flex-direction: column; }
  .complaint-person { display: grid; }
}
