/* Charzoid private support desk and administrator ticket queue. */
html[data-app-route="tickets"],
html[data-app-route="tickets"] body {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.ticket-workspace {
  position: fixed;
  z-index: 90;
  inset: 0;
  display: grid;
  grid-template-rows: var(--app-header-height) minmax(0, 1fr);
  overflow: hidden;
  background: #080a07;
  color: #f1eee4;
  --ticket-paper: #e8dfc9;
  --ticket-olive: #a8ba38;
  --ticket-line: rgba(232, 224, 203, .14);
  --ticket-muted: #aaa99f;
}

.ticket-header {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid rgba(232, 224, 203, .15);
  background: rgba(6, 8, 5, .985);
  box-shadow: 0 12px 36px rgba(0, 0, 0, .35);
}

.ticket-brand { display: flex; min-width: 0; align-items: center; gap: 15px; }
.ticket-brand img { width: var(--app-brand-icon-size); height: var(--app-brand-icon-size); flex: 0 0 var(--app-brand-icon-size); object-fit: contain; }
.ticket-brand div, .ticket-brand strong, .ticket-brand span { display: block; min-width: 0; }
.ticket-brand strong { overflow: hidden; font: 700 clamp(23px, 1.8vw, 30px)/1 "Oswald", sans-serif; text-overflow: ellipsis; white-space: nowrap; }
.ticket-brand span { margin-top: 5px; color: #aeba4e; font-size: 10px; font-weight: 800; letter-spacing: .1em; }
.ticket-header-nav { display: flex; height: 100%; align-items: stretch; }
.ticket-header-actions { display: flex; min-width: 0; align-items: center; gap: 10px; }
.ticket-account-button, .ticket-close {
  display: inline-flex;
  height: var(--app-header-control-height);
  min-height: var(--app-header-control-height);
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 16px;
  border: 1px solid rgba(232, 224, 203, .2);
  border-radius: 7px;
  background: #11140e;
  color: #e9e4d7;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}
.ticket-account-button:hover, .ticket-close:hover { border-color: #a8ba38; background: #1c2214; }
.ticket-account-button img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
.ticket-account-button[data-has-avatar="true"] > i { display: none; }
.ticket-close { border-color: rgba(168, 186, 56, .65); }

.ticket-scroll {
  display: flex;
  min-height: 0;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.ticket-main {
  display: flex;
  width: 100%;
  min-height: 0;
  flex: 1 0 auto;
  flex-direction: column;
  margin: 0;
  padding: 0;
}
.ticket-hero {
  position: relative;
  display: grid;
  min-height: 260px;
  grid-template-columns: minmax(0, 1fr) minmax(310px, 430px);
  align-items: end;
  gap: clamp(28px, 5vw, 80px);
  padding: clamp(36px, 5vw, 76px);
  overflow: hidden;
  border: 0;
  border-bottom: 1px solid var(--ticket-line);
  border-radius: 0;
  background:
    linear-gradient(90deg, rgba(5, 7, 4, .96) 0%, rgba(8, 11, 6, .83) 52%, rgba(8, 11, 6, .55)),
    url("/assets/knox-safehouse.png") center 44% / cover;
  box-shadow: 0 26px 80px rgba(0, 0, 0, .35);
}
.ticket-hero::after { position: absolute; inset: 0; border-bottom: 3px solid rgba(168, 186, 56, .7); content: ""; pointer-events: none; }
.ticket-hero > div, .ticket-hero > aside { position: relative; z-index: 1; }
.ticket-hero p { display: flex; align-items: center; gap: 10px; color: #b7c753; font-size: 12px; font-weight: 900; letter-spacing: .13em; }
.ticket-hero h1 { max-width: 920px; margin: 12px 0 16px; font: 700 clamp(42px, 5vw, 76px)/.98 "Oswald", sans-serif; letter-spacing: -.015em; }
.ticket-hero > div > span { display: block; max-width: 820px; color: #c4c2b9; font-size: clamp(16px, 1.25vw, 20px); line-height: 1.65; }
.ticket-hero aside { display: flex; align-items: flex-start; gap: 17px; padding: 24px; border: 1px solid rgba(168, 186, 56, .3); border-radius: 10px; background: rgba(16, 20, 11, .82); backdrop-filter: blur(10px); }
.ticket-hero aside > i { color: #b8ca4a; font-size: 32px; }
.ticket-hero aside strong, .ticket-hero aside span { display: block; }
.ticket-hero aside strong { margin-bottom: 7px; font: 700 20px/1 "Oswald", sans-serif; }
.ticket-hero aside span { color: #b8b7ad; font-size: 14px; line-height: 1.55; }

.ticket-signed-out {
  display: grid;
  min-height: 390px;
  flex: 1 0 390px;
  grid-template-columns: minmax(260px, .65fr) minmax(380px, 1.35fr);
  align-items: center;
  border: 0;
  border-bottom: 1px solid var(--ticket-line);
  border-radius: 0;
  background: #12150f;
}
.ticket-login-art { display: grid; height: 100%; min-height: 390px; place-items: center; border-right: 1px solid var(--ticket-line); background: radial-gradient(circle, rgba(168, 186, 56, .18), transparent 53%), repeating-linear-gradient(135deg, rgba(255,255,255,.018) 0 1px, transparent 1px 8px); }
.ticket-login-art i { display: grid; width: 132px; height: 132px; place-items: center; border: 1px solid rgba(168, 186, 56, .42); border-radius: 50%; color: #b8ca4a; font-size: 58px; box-shadow: 0 0 0 16px rgba(168, 186, 56, .04); }
.ticket-signed-out > div:last-child { max-width: 760px; padding: clamp(36px, 5vw, 80px); }
.ticket-signed-out p { color: #a9b83d; font-size: 11px; font-weight: 900; letter-spacing: .14em; }
.ticket-signed-out h2 { margin: 12px 0 15px; font: 700 clamp(32px, 3vw, 48px)/1.08 "Oswald", sans-serif; }
.ticket-signed-out div > span { display: block; color: #aaa99f; font-size: 16px; line-height: 1.65; }
.ticket-signed-out button { display: inline-flex; min-height: 56px; align-items: center; gap: 11px; margin-top: 28px; padding: 0 26px; border: 1px solid #b7c842; border-radius: 7px; background: #69751d; color: #fff; cursor: pointer; font-weight: 900; }
.ticket-signed-out button:hover { background: #7d8a25; }

.ticket-console { flex: 1 0 auto; border: 0; border-bottom: 1px solid var(--ticket-line); border-radius: 0; background: #11140e; }
.ticket-console-head { display: grid; min-height: 112px; grid-template-columns: minmax(240px, 1fr) auto auto; align-items: center; gap: 28px; padding: 20px clamp(24px, 3vw, 46px); border-bottom: 1px solid var(--ticket-line); background: #171a13; }
.ticket-console-head > div:first-child p { color: #858b76; font-size: 10px; font-weight: 900; letter-spacing: .12em; }
.ticket-console-head > div:first-child h2 { margin-top: 5px; font: 700 29px/1 "Oswald", sans-serif; }
.ticket-summary-cards { display: flex; align-items: stretch; }
.ticket-summary-cards article { min-width: 118px; padding: 4px 24px; border-left: 1px solid var(--ticket-line); }
.ticket-summary-cards span, .ticket-summary-cards strong { display: block; }
.ticket-summary-cards span { color: #8f9486; font-size: 9px; font-weight: 900; letter-spacing: .11em; }
.ticket-summary-cards strong { margin-top: 4px; color: #e7e2d6; font: 700 30px/1 "Oswald", sans-serif; }
.ticket-new-button { display: inline-flex; min-height: 52px; align-items: center; justify-content: center; gap: 9px; padding: 0 22px; border: 1px solid #b5c543; border-radius: 7px; background: #647019; color: white; cursor: pointer; font-weight: 900; }
.ticket-new-button:hover { background: #798722; }

.ticket-console-grid { display: grid; min-height: 720px; grid-template-columns: minmax(360px, 460px) minmax(0, 1fr); }
.ticket-list-panel { display: flex; min-width: 0; min-height: 0; flex-direction: column; border-right: 1px solid var(--ticket-line); background: #0d100b; }
.ticket-list-panel > header { display: flex; min-height: 72px; flex: 0 0 auto; align-items: center; justify-content: space-between; padding: 0 22px; border-bottom: 1px solid var(--ticket-line); }
.ticket-list-panel > header div { display: flex; align-items: center; gap: 10px; }
.ticket-list-panel > header span { color: #d1d4c8; font-size: 12px; font-weight: 900; letter-spacing: .1em; }
.ticket-list-panel > header strong { display: grid; min-width: 26px; height: 26px; place-items: center; border-radius: 50%; background: #343c12; color: #ceda72; font-size: 11px; }
.ticket-list-panel > header button { display: grid; width: 40px; height: 40px; place-items: center; border: 1px solid var(--ticket-line); border-radius: 6px; background: #151911; color: #c9cabc; cursor: pointer; }
.ticket-list-panel > header button:hover { border-color: rgba(168, 186, 56, .55); color: #dbe87d; }
.ticket-list-panel > header button:disabled { cursor: wait; opacity: .7; }
.ticket-list-panel > header button[data-loading="true"] i { animation: ticket-refresh-spin .8s linear infinite; }
@keyframes ticket-refresh-spin { to { transform: rotate(360deg); } }
.ticket-list-filters { display: grid; flex: 0 0 auto; gap: 13px; padding: 18px 20px; border-bottom: 1px solid var(--ticket-line); background: linear-gradient(180deg, #151912, #10130e); }
.ticket-filter-search { position: relative; display: flex; align-items: center; }
.ticket-filter-search > i { position: absolute; left: 15px; z-index: 1; color: #8f967f; font-size: 15px; pointer-events: none; }
.ticket-filter-search input { width: 100%; height: 48px; padding: 0 42px; border: 1px solid rgba(232, 224, 203, .18); border-radius: 7px; outline: 0; background: #090c08; color: #f1eee4; font-size: 14px; font-weight: 650; }
.ticket-filter-search input::placeholder { color: #8d9384; opacity: 1; }
.ticket-filter-search:focus-within input { border-color: #a8ba38; box-shadow: 0 0 0 3px rgba(168, 186, 56, .1); }
.ticket-filter-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; padding: 4px; border: 1px solid rgba(232, 224, 203, .12); border-radius: 8px; background: #090c08; }
.ticket-filter-tabs button { display: flex; min-width: 0; min-height: 42px; align-items: center; justify-content: center; gap: 7px; padding: 0 8px; border: 1px solid transparent; border-radius: 5px; background: transparent; color: #919889; cursor: pointer; font-size: 10px; font-weight: 900; letter-spacing: .055em; }
.ticket-filter-tabs button:hover { color: #e4e7dc; }
.ticket-filter-tabs button.active { border-color: rgba(168, 186, 56, .48); background: linear-gradient(180deg, #424d18, #2c3411); color: #f3f7d4; box-shadow: 0 6px 16px rgba(0, 0, 0, .2); }
.ticket-filter-tabs button strong { display: grid; min-width: 21px; height: 21px; place-items: center; padding: 0 5px; border-radius: 999px; background: rgba(255, 255, 255, .08); color: inherit; font-size: 9px; }
.ticket-filter-tabs button.active strong { background: rgba(215, 231, 111, .2); }
.ticket-filter-controls { display: flex; min-width: 0; align-items: end; gap: 9px; }
.ticket-filter-controls label { display: grid; min-width: 0; flex: 1 1 auto; gap: 7px; color: #aeb4a3; font-size: 9px; font-weight: 900; letter-spacing: .1em; }
.ticket-filter-controls select { width: 100%; height: 44px; padding: 0 36px 0 12px; border: 1px solid rgba(232, 224, 203, .18); border-radius: 6px; outline: 0; background: #11150f; color: #e6e4db; font-size: 12px; font-weight: 800; }
.ticket-filter-controls select:focus { border-color: #a8ba38; }
.ticket-filter-reset { display: inline-flex; min-height: 44px; align-items: center; justify-content: center; gap: 7px; padding: 0 12px; border: 1px solid rgba(168, 186, 56, .28); border-radius: 6px; background: rgba(71, 82, 25, .35); color: #d6df8b; cursor: pointer; font-size: 9px; font-weight: 900; letter-spacing: .07em; }
.ticket-filter-reset:hover { border-color: #a8ba38; background: rgba(92, 106, 30, .52); }
.ticket-filter-result { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 12px; color: #c5cbb9; font-size: 11px; font-weight: 900; letter-spacing: .07em; }
.ticket-filter-result small { display: inline-flex; align-items: center; gap: 5px; color: #96a467; font-size: 9px; white-space: nowrap; }
.ticket-filter-result small i { color: #b9cc42; }
.ticket-list { min-height: 250px; max-height: 600px; flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; scrollbar-color: #4b5520 #0d100b; }
.ticket-list > p { padding: 28px; color: #a8ae9f; font-size: 14px; line-height: 1.55; }
.ticket-list-empty { display: grid; min-height: 280px; place-content: center; justify-items: center; padding: 34px 28px; color: #969d8e; text-align: center; }
.ticket-list-empty > i { margin-bottom: 13px; color: #687147; font-size: 38px; }
.ticket-list-empty strong { color: #e0e3d8; font: 700 22px/1.1 "Oswald", sans-serif; }
.ticket-list-empty p { max-width: 310px; margin-top: 9px; font-size: 13px; line-height: 1.55; }
.ticket-list-empty button { display: inline-flex; min-height: 40px; align-items: center; gap: 7px; margin-top: 18px; padding: 0 14px; border: 1px solid rgba(168, 186, 56, .45); border-radius: 6px; background: #303814; color: #e5edaa; cursor: pointer; font-size: 10px; font-weight: 900; }
.ticket-list-item { display: block; width: 100%; padding: 19px 22px; border: 0; border-bottom: 1px solid var(--ticket-line); background: transparent; color: inherit; cursor: pointer; text-align: left; }
.ticket-list-item:hover, .ticket-list-item.active { background: #1b2014; }
.ticket-list-item.active { box-shadow: inset 4px 0 #a8ba38; }
.ticket-list-item:focus-visible { position: relative; z-index: 1; outline: 2px solid #b9cc42; outline-offset: -3px; }
.ticket-list-item > span:first-child { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: #969d8d; font: 800 11px/1.2 var(--mono, monospace); }
.ticket-list-item h3 { margin: 9px 0 7px; overflow: hidden; color: #f0eee7; font: 700 21px/1.15 "Oswald", sans-serif; text-overflow: ellipsis; white-space: nowrap; }
.ticket-list-item p { display: -webkit-box; overflow: hidden; color: #b8bbb1; font-size: 14px; line-height: 1.5; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.ticket-list-item footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; color: #949a8c; font-size: 10px; font-weight: 800; }

.ticket-detail-panel { min-width: 0; background: radial-gradient(circle at 70% 10%, rgba(168, 186, 56, .05), transparent 30rem), #13160f; }
.ticket-detail-empty { display: grid; min-height: 660px; place-content: center; justify-items: center; padding: 40px; text-align: center; }
.ticket-detail-empty i { color: #59613d; font-size: 60px; }
.ticket-detail-empty .ticket-detail-loading-icon { animation: ticket-refresh-spin .9s linear infinite; }
.ticket-detail-empty h3 { margin-top: 17px; font: 700 30px/1 "Oswald", sans-serif; }
.ticket-detail-empty p { margin-top: 9px; color: #8e9386; font-size: 14px; }
.ticket-detail { min-height: 660px; }
.ticket-detail-head { display: flex; min-height: 98px; align-items: center; justify-content: space-between; gap: 20px; padding: 20px clamp(24px, 3vw, 42px); border-bottom: 1px solid var(--ticket-line); }
.ticket-detail-head > div:first-child span { color: #9aa17d; font: 800 10px var(--mono, monospace); letter-spacing: .08em; }
.ticket-detail-head h3 { margin-top: 5px; font: 700 clamp(23px, 2vw, 32px)/1.1 "Oswald", sans-serif; }
.ticket-detail-head > div:last-child { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.ticket-status-badge, .ticket-priority-badge, .ticket-mini-badge { display: inline-flex; min-height: 28px; align-items: center; justify-content: center; padding: 0 10px; border: 1px solid rgba(168, 186, 56, .35); border-radius: 999px; background: rgba(168, 186, 56, .1); color: #cbd76f; font-size: 9px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.ticket-status-badge[data-status="resolved"], .ticket-status-badge[data-status="closed"] { border-color: rgba(131, 146, 124, .35); background: rgba(131, 146, 124, .1); color: #a7b3a1; }
.ticket-status-badge[data-status="waiting_player"] { border-color: rgba(205, 143, 56, .4); background: rgba(205, 143, 56, .1); color: #e1ad63; }
.ticket-mini-badge[data-status="resolved"], .ticket-mini-badge[data-status="closed"] { border-color: rgba(131, 146, 124, .35); background: rgba(131, 146, 124, .1); color: #b3beb0; }
.ticket-mini-badge[data-status="waiting_player"] { border-color: rgba(205, 143, 56, .4); background: rgba(205, 143, 56, .1); color: #e1ad63; }
.ticket-priority-badge[data-priority="urgent"] { border-color: rgba(219, 105, 85, .45); background: rgba(219, 105, 85, .1); color: #ef8e7d; }
.ticket-priority-badge[data-priority="high"] { border-color: rgba(205, 143, 56, .45); background: rgba(205, 143, 56, .1); color: #e3ac60; }
.ticket-list-badges { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.ticket-origin-badge { display: inline-flex; min-height: 28px; align-items: center; gap: 5px; padding: 0 9px; border: 1px solid rgba(114, 176, 197, .38); border-radius: 999px; background: rgba(76, 139, 160, .11); color: #9ed3df; font-size: 8px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.ticket-origin-meta { color: #9ed3df !important; }
.ticket-detail-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 12px clamp(24px, 3vw, 42px); border-bottom: 1px solid var(--ticket-line); color: #858b7e; font-size: 11px; }
.ticket-detail-meta span { display: inline-flex; align-items: center; gap: 7px; }
.ticket-thread { display: flex; max-height: 480px; min-height: 340px; flex-direction: column; gap: 18px; padding: 30px clamp(24px, 3vw, 42px); overflow-y: auto; }
.ticket-message { width: min(78%, 760px); }
.ticket-message[data-author="player"] { align-self: flex-end; }
.ticket-message header { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 7px; color: #858b7e; font-size: 10px; font-weight: 800; }
.ticket-message p { padding: 16px 18px; border: 1px solid var(--ticket-line); border-radius: 10px 10px 10px 2px; background: #1c2117; color: #ddd9cf; font-size: 14px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.ticket-message[data-author="player"] p { border-color: rgba(168, 186, 56, .3); border-radius: 10px 10px 2px 10px; background: #282f18; }
.ticket-message[data-author="system"] header strong { color: #9ed3df; }
.ticket-message[data-author="system"] p { border-style: dashed; border-color: rgba(114, 176, 197, .32); background: rgba(44, 83, 94, .18); }
.ticket-reply-form { padding: 24px clamp(24px, 3vw, 42px) 30px; border-top: 1px solid var(--ticket-line); background: #0e110c; }
.ticket-reply-form > label { display: block; margin-bottom: 8px; color: #9da58b; font-size: 10px; font-weight: 900; letter-spacing: .1em; }
.ticket-reply-form textarea { width: 100%; min-height: 100px; resize: vertical; padding: 14px; border: 1px solid rgba(232, 224, 203, .2); border-radius: 7px; outline: 0; background: #171b13; color: #f0ece2; font-size: 14px; line-height: 1.55; }
.ticket-reply-form textarea:focus { border-color: #a8ba38; box-shadow: 0 0 0 3px rgba(168, 186, 56, .1); }
.ticket-reply-form > div { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 12px; }
.ticket-reply-form > div > span { color: #787e73; font-size: 11px; }
.ticket-reply-form button { display: inline-flex; min-height: 44px; align-items: center; gap: 8px; padding: 0 18px; border: 1px solid #a8ba38; border-radius: 6px; background: #5f6b17; color: #fff; cursor: pointer; font-weight: 900; }
.ticket-reply-form button:disabled, .ticket-dialog-actions button:disabled { cursor: wait; opacity: .55; }
.ticket-form-error { min-height: 18px; margin-top: 8px; color: #ef8f7d; font-size: 12px; }

.ticket-create-dialog { width: min(720px, calc(100vw - 28px)); max-height: calc(100vh - 30px); padding: 0; overflow: auto; border: 1px solid rgba(168, 186, 56, .4); border-radius: 12px; background: #11140e; color: #f0ede3; box-shadow: 0 34px 100px rgba(0,0,0,.7); }
.ticket-create-dialog::backdrop { background: rgba(0, 0, 0, .78); backdrop-filter: blur(5px); }
.ticket-create-dialog form { position: relative; padding: clamp(27px, 4vw, 46px); }
.ticket-dialog-close { position: absolute; top: 18px; right: 18px; display: grid; width: 40px; height: 40px; place-items: center; border: 1px solid var(--ticket-line); border-radius: 6px; background: #191d14; cursor: pointer; }
.ticket-dialog-mark { display: grid; width: 58px; height: 58px; place-items: center; margin-bottom: 20px; border-radius: 9px; background: #a8ba38; color: #13160d; font-size: 27px; }
.ticket-create-dialog form > p:first-of-type { color: #aeba4e; font-size: 10px; font-weight: 900; letter-spacing: .13em; }
.ticket-create-dialog h2 { margin: 8px 0 26px; font: 700 clamp(30px, 4vw, 42px)/1.05 "Oswald", sans-serif; }
.ticket-create-dialog label { display: grid; gap: 8px; margin-bottom: 18px; color: #aeb3a5; font-size: 10px; font-weight: 900; letter-spacing: .09em; }
.ticket-create-dialog input, .ticket-create-dialog select, .ticket-create-dialog textarea { width: 100%; min-height: 50px; padding: 12px 14px; border: 1px solid rgba(232, 224, 203, .2); border-radius: 6px; outline: 0; background: #191d14; color: #f0ede3; font-size: 14px; font-weight: 500; letter-spacing: 0; }
.ticket-create-dialog textarea { min-height: 160px; resize: vertical; line-height: 1.55; }
.ticket-create-dialog input:focus, .ticket-create-dialog select:focus, .ticket-create-dialog textarea:focus { border-color: #a8ba38; box-shadow: 0 0 0 3px rgba(168,186,56,.1); }
.ticket-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.ticket-form-guidance { display: flex; align-items: flex-start; gap: 9px; padding: 12px; border: 1px solid rgba(205, 143, 56, .25); border-radius: 6px; background: rgba(205, 143, 56, .07); color: #c8ad86 !important; font-size: 12px !important; font-weight: 600 !important; letter-spacing: 0 !important; line-height: 1.45; }
.ticket-dialog-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.ticket-dialog-actions button { display: inline-flex; min-height: 48px; align-items: center; gap: 8px; padding: 0 20px; border: 1px solid var(--ticket-line); border-radius: 6px; background: #191d14; cursor: pointer; font-weight: 900; }
.ticket-dialog-actions button:last-child { border-color: #a8ba38; background: #637019; color: white; }
.ticket-footer { width: 100%; flex: 0 0 auto; margin: 0; }

/* Admin queue */
.admin-nav-button { position: relative; }
.admin-nav-badge { display: grid; min-width: 25px; height: 25px; place-items: center; margin-left: auto; padding: 0 7px; border-radius: 999px; background: #a8ba38; color: #11140d; font-size: 10px; font-weight: 900; }
.admin-ticket-dashboard { display: grid; min-width: 0; gap: 18px; }
.admin-ticket-toolbar { display: grid; min-width: 0; grid-template-columns: minmax(240px, 1fr) minmax(160px, 190px) minmax(160px, 190px) auto; align-items: end; gap: 12px; padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: #11150f; }
.admin-ticket-toolbar label { display: grid; min-width: 0; gap: 8px; color: #c3cbb7; font-size: 12px; font-weight: 900; letter-spacing: .08em; }
.admin-ticket-toolbar input, .admin-ticket-toolbar select { width: 100%; max-width: 100%; min-height: 50px; padding: 0 15px; border: 1px solid var(--line-strong); border-radius: 5px; outline: 0; background: #090c08; color: #f2f4ec; font-size: 15px; }
.admin-ticket-select { position: relative; display: block; min-width: 0; width: 100%; }
.admin-ticket-select select { width: 100%; padding-right: 48px; appearance: none; -webkit-appearance: none; }
.admin-ticket-select > i { position: absolute; top: 50%; right: 16px; display: grid; width: 20px; height: 20px; place-items: center; transform: translateY(-50%); color: #cbd777; font-size: 14px; line-height: 1; pointer-events: none; }
.admin-ticket-toolbar input::placeholder, .admin-ticket-composer textarea::placeholder { color: #a7ad9e; opacity: 1; }
.admin-ticket-toolbar input:focus, .admin-ticket-toolbar select:focus { border-color: var(--moss); }
.admin-ticket-toolbar button { align-self: end; min-height: 50px; padding: 0 20px; border: 1px solid rgba(184,207,75,.5); border-radius: 5px; background: #283014; color: #f2f7c9; cursor: pointer; font-size: 14px; font-weight: 900; }
.admin-ticket-filter-status { display: inline-flex; min-height: 50px; align-items: center; justify-content: center; gap: 9px; padding: 0 16px; border: 1px solid rgba(184,207,75,.28); border-radius: 5px; background: rgba(40,48,20,.48); color: #dce6a4; font-size: 11px; font-weight: 900; letter-spacing: .055em; line-height: 1.25; text-align: center; }
.admin-ticket-filter-status i { flex: 0 0 auto; color: var(--moss); font-size: 16px; }
.admin-ticket-filter-status[data-loading="true"] i { animation: admin-ticket-filter-spin .8s linear infinite; }
@keyframes admin-ticket-filter-spin { to { transform: rotate(360deg); } }
.admin-ticket-metrics { display: grid; grid-template-columns: repeat(5, minmax(120px, 1fr)); gap: 10px; }
.admin-ticket-metrics article { padding: 18px 20px; border: 1px solid var(--line); border-radius: 7px; background: #11150f; }
.admin-ticket-metrics span, .admin-ticket-metrics strong { display: block; }
.admin-ticket-metrics span { color: #bcc4b1; font-size: 12px; font-weight: 900; letter-spacing: .08em; }
.admin-ticket-metrics strong { margin-top: 8px; color: #f3f0e7; font: 700 34px/1 "Oswald", sans-serif; }
.admin-ticket-layout { display: grid; width: 100%; min-width: 0; min-height: 680px; grid-template-columns: minmax(330px, 430px) minmax(0, 1fr); overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: #0c0f0b; }
.admin-ticket-queue { max-height: 760px; overflow-y: auto; border-right: 1px solid var(--line); }
.admin-ticket-queue-empty { padding: 32px; color: #b3baaa; font-size: 15px; line-height: 1.6; }
.admin-ticket-row { width: 100%; padding: 21px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: #f1eee5; cursor: pointer; text-align: left; }
.admin-ticket-row:hover, .admin-ticket-row.active { background: #182014; }
.admin-ticket-row.active { box-shadow: inset 4px 0 var(--moss); }
.admin-ticket-row header, .admin-ticket-row footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.admin-ticket-row header { color: #adb5a3; font: 800 12px var(--mono); }
.admin-ticket-row h4 { margin: 10px 0 7px; overflow: hidden; color: #f2efe6; font-size: 19px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.admin-ticket-row p { display: -webkit-box; overflow: hidden; color: #ccd1c5; font-size: 15px; line-height: 1.5; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.admin-ticket-row footer { margin-top: 13px; color: #a2aa9b; font-size: 12px; }
.admin-ticket-origin { color: #8fc8d6; font-weight: 900; }
.admin-ticket-inspector { min-width: 0; overflow: hidden; }
.admin-ticket-empty { display: grid; min-height: 680px; place-content: center; justify-items: center; padding: 32px; color: #b7beaf; font-size: 15px; line-height: 1.6; text-align: center; }
.admin-ticket-empty i { margin-bottom: 12px; font-size: 44px; }
.admin-ticket-empty h4 { margin: 0 0 7px; color: #dfe3d6; font-size: 19px; }
.admin-ticket-detail-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 22px; border-bottom: 1px solid var(--line); background: #121710; }
.admin-ticket-detail-head span { color: #b3bba6; font: 800 12px var(--mono); }
.admin-ticket-detail-head h4 { margin: 7px 0; color: #f3f0e7; font-size: 27px; line-height: 1.2; }
.admin-ticket-detail-head p { color: #c2c9bc; font-size: 14px; line-height: 1.5; }
.admin-ticket-detail-head .admin-ticket-discord { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin-top: 10px; color: #a9d8e2; font-size: 13px; overflow-wrap: anywhere; }
.admin-ticket-discord i { font-size: 16px; }
.admin-ticket-discord strong { color: #d4edf2; letter-spacing: .04em; }
.admin-ticket-controls { display: grid; grid-template-columns: repeat(3, minmax(130px, 1fr)); gap: 10px; padding: 16px 22px; border-bottom: 1px solid var(--line); }
.admin-ticket-controls label { display: grid; gap: 7px; color: #bac2af; font-size: 12px; font-weight: 900; letter-spacing: .08em; }
.admin-ticket-controls select, .admin-ticket-controls button { min-height: 46px; padding: 0 13px; border: 1px solid var(--line-strong); border-radius: 4px; background: #090c08; color: #f0f2ea; font-size: 14px; }
.admin-ticket-controls .admin-ticket-select select { padding-right: 44px; }
.admin-ticket-controls .admin-ticket-select > i { right: 14px; }
.admin-ticket-controls button { align-self: end; cursor: pointer; font-weight: 900; }
.admin-ticket-thread { display: flex; max-height: 390px; min-height: 300px; flex-direction: column; gap: 12px; padding: 22px; overflow-y: auto; }
.admin-ticket-message { width: min(82%, 720px); }
.admin-ticket-message[data-author="player"] { align-self: flex-start; }
.admin-ticket-message[data-author="admin"] { align-self: flex-end; }
.admin-ticket-message header { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 7px; color: #aeb6a5; font-size: 12px; }
.admin-ticket-message p { padding: 15px 17px; border: 1px solid var(--line); border-radius: 7px; background: #181d15; color: #eef0e9; font-size: 15px; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.admin-ticket-message[data-author="admin"] p { border-color: rgba(184,207,75,.25); background: #222a17; }
.admin-ticket-message[data-private="true"] p { border-style: dashed; border-color: rgba(207,143,56,.35); background: rgba(207,143,56,.08); }
.admin-ticket-composer { padding: 18px 22px 22px; border-top: 1px solid var(--line); background: #10140e; }
.admin-ticket-composer textarea { width: 100%; min-height: 110px; resize: vertical; padding: 15px; border: 1px solid var(--line-strong); border-radius: 5px; outline: 0; background: #090c08; color: #f1f3ec; font-size: 15px; line-height: 1.6; }
.admin-ticket-composer textarea:focus { border-color: var(--moss); }
.admin-ticket-composer footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; }
.admin-ticket-composer footer > span { color: #abb3a3; font-size: 12px; }
.admin-ticket-composer footer div { display: flex; gap: 8px; }
.admin-ticket-composer button { min-height: 44px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: 4px; background: #171d13; color: #edf0e7; cursor: pointer; font-size: 13px; font-weight: 900; }
.admin-ticket-composer button:last-child { border-color: rgba(184,207,75,.5); background: #2c3716; color: #edf3bd; }
.admin-ticket-event-log { padding: 0 22px 22px; }
.admin-ticket-event-log details { border-top: 1px solid var(--line); padding-top: 14px; }
.admin-ticket-event-log summary { color: #b4bca9; cursor: pointer; font-size: 12px; font-weight: 900; letter-spacing: .08em; }
.admin-ticket-event-log ul { display: grid; gap: 7px; margin: 12px 0 0; padding: 0; list-style: none; }
.admin-ticket-event-log li { color: #aeb6a6; font-size: 13px; line-height: 1.45; }

@media (min-width: 1600px) {
  .admin-ticket-toolbar { grid-template-columns: minmax(300px, 1fr) 220px 220px auto; }
  .admin-ticket-layout { grid-template-columns: minmax(390px, 500px) minmax(0, 1fr); }
  .admin-ticket-row h4 { font-size: 20px; }
  .admin-ticket-message { width: min(78%, 860px); }
  .admin-ticket-message p, .admin-ticket-composer textarea { font-size: 16px; }
}

@media (max-width: 1250px) {
  .ticket-header-tier { display: none !important; }
  .ticket-close span { display: none; }
  .ticket-close { width: 50px; padding: 0; }
  .ticket-console-grid { grid-template-columns: 340px minmax(0, 1fr); }
  .admin-ticket-toolbar { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .admin-ticket-toolbar label:first-child, .admin-ticket-filter-status { grid-column: 1 / -1; }
  .admin-ticket-layout { grid-template-columns: 340px minmax(0, 1fr); }
  .admin-ticket-controls { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 1100px) {
  .admin-ticket-layout { min-height: 0; grid-template-columns: 1fr; }
  .admin-ticket-queue { max-height: 330px; border-right: 0; border-bottom: 1px solid var(--line); }
  .admin-ticket-row h4 { white-space: normal; }
  .admin-ticket-detail-head { align-items: flex-start; flex-direction: column; }
  .admin-ticket-message { width: 92%; }
}

@media (max-width: 900px) {
  .ticket-workspace { grid-template-rows: 78px minmax(0, 1fr); }
  .ticket-header { height: 78px; min-height: 78px; max-height: 78px; padding: 0 14px; }
  .ticket-header-nav { display: none; }
  .ticket-brand { gap: 8px; }
  .ticket-brand img { width: 46px; height: 46px; flex-basis: 46px; }
  .ticket-brand strong { font-size: 21px; }
  .ticket-brand span { display: none; }
  .ticket-account-button { max-width: 150px; padding: 0 10px; }
  .ticket-account-button span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ticket-main { width: 100%; padding: 0; }
  .ticket-hero { min-height: 310px; grid-template-columns: 1fr; align-content: end; padding: 30px; }
  .ticket-hero h1 { font-size: clamp(40px, 10vw, 58px); }
  .ticket-hero aside { display: none; }
  .ticket-signed-out { grid-template-columns: 1fr; }
  .ticket-login-art { display: none; }
  .ticket-console-head { grid-template-columns: 1fr auto; }
  .ticket-summary-cards { display: none; }
  .ticket-console-grid { grid-template-columns: 1fr; }
  .ticket-list-panel { border-right: 0; border-bottom: 1px solid var(--ticket-line); }
  .ticket-list { max-height: 330px; }
  .ticket-detail-empty { min-height: 320px; }
  .ticket-message { width: 90%; }
  .admin-ticket-toolbar { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .admin-ticket-toolbar label:first-child, .admin-ticket-filter-status { grid-column: 1 / -1; }
  .admin-ticket-metrics { grid-template-columns: repeat(3, 1fr); }
  .admin-ticket-layout { min-height: 0; grid-template-columns: 1fr; }
  .admin-ticket-queue { max-height: 330px; border-right: 0; border-bottom: 1px solid var(--line); }
  .admin-ticket-controls { grid-template-columns: 1fr 1fr; }
  .admin-ticket-row h4 { white-space: normal; }
  .admin-ticket-detail-head { align-items: flex-start; flex-direction: column; }
  .admin-ticket-message { width: 92%; }
}

@media (max-width: 560px) {
  .ticket-header-actions { gap: 5px; }
  .ticket-header .language-toggle { min-width: 42px; padding: 0; }
  .ticket-account-button { width: 46px; padding: 0; }
  .ticket-account-button span { display: none; }
  .ticket-close { width: 44px; }
  .ticket-main { width: 100%; padding: 0 0 24px; }
  .ticket-hero { min-height: 330px; border-width: 0 0 3px; border-radius: 0; padding: 28px 20px; }
  .ticket-hero p { font-size: 10px; }
  .ticket-hero h1 { font-size: 43px; }
  .ticket-hero > div > span { font-size: 14px; line-height: 1.55; }
  .ticket-signed-out, .ticket-console { border-width: 0; border-radius: 0; }
  .ticket-signed-out > div:last-child { padding: 38px 22px; }
  .ticket-console-head { padding: 18px; }
  .ticket-new-button span { display: none; }
  .ticket-new-button { width: 48px; padding: 0; }
  .ticket-detail-head, .ticket-reply-form, .ticket-thread { padding-right: 18px; padding-left: 18px; }
  .ticket-detail-head { align-items: flex-start; flex-direction: column; }
  .ticket-message { width: 96%; }
  .ticket-reply-form > div { align-items: flex-start; flex-direction: column; }
  .ticket-reply-form button { width: 100%; justify-content: center; }
  .ticket-form-row { grid-template-columns: 1fr; gap: 0; }
  .ticket-dialog-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .ticket-footer { width: 100%; }
  .admin-ticket-toolbar { grid-template-columns: minmax(0, 1fr); padding: 16px; }
  .admin-ticket-toolbar label:first-child, .admin-ticket-filter-status { grid-column: auto; }
  .admin-ticket-filter-status { justify-content: flex-start; text-align: left; }
  .admin-ticket-metrics { grid-template-columns: repeat(2, 1fr); }
  .admin-ticket-metrics article { padding: 15px 16px; }
  .admin-ticket-metrics strong { font-size: 30px; }
  .admin-ticket-row { padding: 19px 17px; }
  .admin-ticket-row header, .admin-ticket-row footer { align-items: flex-start; flex-direction: column; }
  .admin-ticket-detail-head, .admin-ticket-controls, .admin-ticket-thread, .admin-ticket-composer, .admin-ticket-event-log { padding-right: 16px; padding-left: 16px; }
  .admin-ticket-controls { grid-template-columns: 1fr; }
  .admin-ticket-message { width: 100%; }
  .admin-ticket-message header { align-items: flex-start; flex-direction: column; }
  .admin-ticket-composer footer { align-items: stretch; flex-direction: column; }
  .admin-ticket-composer footer div { display: grid; grid-template-columns: 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .ticket-detail-empty .ticket-detail-loading-icon,
  .admin-ticket-filter-status[data-loading="true"] i { animation: none; }
}

/* Player ticket inbox overhaul — full-height, readable, and mobile-first. */
.ticket-workspace[data-authenticated="true"] .ticket-hero { display: none; }
.ticket-workspace[data-authenticated="true"] .ticket-scroll { overflow: hidden; }
.ticket-workspace[data-authenticated="true"] .ticket-main { min-height: 0; flex: 1 1 auto; overflow: hidden; }
.ticket-workspace[data-authenticated="true"] .ticket-footer { min-height: 38px; }
.ticket-console:not([hidden]) {
  display: flex;
  min-height: 0;
  flex: 1 1 auto;
  flex-direction: column;
  overflow: hidden;
  background:
    radial-gradient(circle at 76% 12%, rgba(168, 186, 56, .055), transparent 32rem),
    #0e110c;
}
.ticket-console-head {
  min-height: 94px;
  flex: 0 0 auto;
  grid-template-columns: minmax(250px, 1fr) auto auto;
  gap: clamp(20px, 3vw, 48px);
  padding: 16px clamp(24px, 3vw, 48px);
  background: linear-gradient(180deg, #1a1e15, #141811);
}
.ticket-console-identity { display: flex; min-width: 0; align-items: center; gap: 15px; }
.ticket-console-mark { display: grid; width: 48px; height: 48px; flex: 0 0 48px; place-items: center; overflow: hidden; border: 1px solid rgba(168, 186, 56, .42); border-radius: 10px; background: #293114; color: #c5d75a; font-size: 22px; }
.ticket-console-mark img { width: 100%; height: 100%; object-fit: cover; }
.ticket-console-mark[data-has-avatar="true"] > i { display: none; }
.ticket-console-head .ticket-console-identity p { color: #aeb69a; font-size: 11px; }
.ticket-console-head .ticket-console-identity h2 { overflow: hidden; margin-top: 5px; color: #f4f0e6; font-size: clamp(26px, 2vw, 34px); text-overflow: ellipsis; white-space: nowrap; }
.ticket-summary-cards article { min-width: 132px; padding: 5px 28px; }
.ticket-summary-cards span { color: #aeb5a3; font-size: 10px; }
.ticket-summary-cards strong { color: #f3efe5; font-size: 33px; }
.ticket-new-button { min-height: 54px; padding: 0 24px; font-size: 13px; letter-spacing: .035em; }

.ticket-console-toolbar {
  display: grid;
  min-width: 0;
  flex: 0 0 auto;
  grid-template-columns: minmax(260px, 1fr) minmax(300px, 350px) minmax(330px, 380px) auto;
  align-items: center;
  gap: 14px;
  padding: 14px clamp(22px, 2.5vw, 40px);
  border-bottom: 1px solid var(--ticket-line);
  background: #0b0e0a;
}
.ticket-console-toolbar .ticket-filter-search input { height: 50px; font-size: 15px; }
.ticket-console-toolbar .ticket-filter-tabs { min-width: 320px; }
.ticket-console-toolbar .ticket-filter-tabs button { min-height: 42px; font-size: 11px; }
.ticket-console-toolbar .ticket-filter-controls { align-items: center; }
.ticket-console-toolbar .ticket-filter-controls label { gap: 4px; font-size: 9px; }
.ticket-console-toolbar .ticket-filter-controls select { height: 50px; font-size: 13px; }
.ticket-console-toolbar .ticket-filter-reset { min-height: 50px; }
.ticket-console-toolbar .ticket-filter-result { min-width: 150px; flex-direction: column; align-items: flex-end; gap: 4px; font-size: 11px; text-align: right; }

.ticket-console-grid {
  display: grid;
  min-height: 0;
  flex: 1 1 auto;
  grid-template-columns: minmax(350px, 410px) minmax(0, 1fr);
  overflow: hidden;
}
.ticket-console[data-has-visible-tickets="false"] .ticket-console-grid { grid-template-columns: minmax(0, 1fr); }
.ticket-console[data-has-visible-tickets="false"] .ticket-detail-panel { display: none; }
.ticket-list-panel { min-height: 0; overflow: hidden; }
.ticket-list-panel > header { min-height: 66px; padding: 0 24px; }
.ticket-list-panel > header span { color: #e2e5da; font-size: 13px; }
.ticket-list-panel > header strong { min-width: 30px; height: 30px; font-size: 12px; }
.ticket-list { min-height: 0; max-height: none; flex: 1 1 auto; }
.ticket-list-empty { min-height: 100%; padding: 48px 28px; }
.ticket-list-empty > i { color: #9aaa42; font-size: 48px; }
.ticket-list-empty strong { color: #f1eee5; font-size: 27px; }
.ticket-list-empty p { max-width: 430px; color: #b9beb1; font-size: 15px; line-height: 1.65; }
.ticket-list-empty button { min-height: 47px; padding: 0 18px; font-size: 11px; }
.ticket-list-item { padding: 21px 24px; }
.ticket-list-item > span:first-child { color: #b0b7a5; font-size: 12px; }
.ticket-list-item h3 { margin: 10px 0 8px; font-size: 23px; }
.ticket-list-item p { color: #c7cbc0; font-size: 14px; line-height: 1.55; }
.ticket-list-item footer { margin-top: 15px; color: #a9b09f; font-size: 11px; }
.ticket-origin-badge { font-size: 9px; }

.ticket-detail-panel { min-height: 0; overflow: hidden; }
.ticket-detail-empty { min-height: 100%; }
.ticket-detail-empty h3 { color: #f0ede3; font-size: 34px; }
.ticket-detail-empty p { max-width: 420px; color: #aeb4a7; font-size: 15px; line-height: 1.6; }
.ticket-detail:not([hidden]) { display: grid; height: 100%; min-height: 0; grid-template-rows: auto auto minmax(0, 1fr) auto; overflow: hidden; }
.ticket-detail-head { min-height: 102px; padding: 18px clamp(24px, 3vw, 46px); }
.ticket-detail-title { min-width: 0; flex: 1 1 auto; }
.ticket-detail-head .ticket-detail-title > span { color: #b4bd8d; font: 800 12px var(--mono, monospace); letter-spacing: .08em; }
.ticket-detail-head h3 { overflow-wrap: anywhere; color: #f5f1e7; font-size: clamp(25px, 2vw, 34px); }
.ticket-mobile-back { display: none; }
.ticket-detail-meta { gap: 9px 24px; padding: 13px clamp(24px, 3vw, 46px); color: #afb6a7; font-size: 12px; }
.ticket-thread { min-height: 0; max-height: none; gap: 20px; padding: 28px clamp(24px, 3vw, 46px); }
.ticket-message { width: min(76%, 820px); }
.ticket-message header { color: #aeb5a6; font-size: 11px; }
.ticket-message p { color: #eeeae0; font-size: 15px; line-height: 1.65; }
.ticket-reply-form { padding: 14px clamp(24px, 3vw, 46px) 16px; }
.ticket-reply-form > label { color: #c2c9b8; font-size: 11px; }
.ticket-reply-form textarea { height: 72px; min-height: 68px; max-height: 130px; color: #f4f1e8; font-size: 15px; }
.ticket-reply-form > div > span { color: #a8aea1; font-size: 12px; }
.ticket-reply-form button { min-height: 47px; padding: 0 20px; font-size: 12px; }
.ticket-reply-form .ticket-form-error:empty { display: none; }

.ticket-closed-actions {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 17px;
  padding: 20px clamp(24px, 3vw, 46px);
  border-top: 1px solid rgba(168, 186, 56, .28);
  background: linear-gradient(90deg, rgba(57, 67, 25, .62), rgba(31, 37, 20, .85));
}
.ticket-closed-actions[hidden] { display: none; }
.ticket-closed-actions > i { display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid rgba(188, 207, 83, .45); border-radius: 50%; color: #cfde70; font-size: 20px; }
.ticket-closed-actions strong, .ticket-closed-actions span { display: block; }
.ticket-closed-actions strong { margin-bottom: 4px; color: #f0f2d3; font: 700 18px/1.1 "Oswald", sans-serif; }
.ticket-closed-actions div > span { color: #c6cab9; font-size: 13px; line-height: 1.5; }
.ticket-closed-actions button { display: inline-flex; min-height: 48px; align-items: center; gap: 9px; padding: 0 18px; border: 1px solid #b8ca4a; border-radius: 6px; background: #66731b; color: white; cursor: pointer; font-size: 11px; font-weight: 900; letter-spacing: .04em; }
.ticket-closed-actions button:hover { background: #7b8923; }
.ticket-closed-actions button:disabled { cursor: wait; opacity: .55; }
.ticket-reopen-note { margin: -12px 0 24px; color: #bec4b7; font-size: 15px; line-height: 1.65; }

@media (max-width: 1320px) {
  .ticket-console-toolbar { grid-template-columns: minmax(220px, 1fr) minmax(280px, auto) minmax(280px, 320px); }
  .ticket-console-toolbar .ticket-filter-result { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: flex-end; }
  .ticket-console-grid { grid-template-columns: minmax(320px, 370px) minmax(0, 1fr); }
}

@media (max-width: 900px) {
  .ticket-workspace[data-authenticated="true"] .ticket-footer { display: none; }
  .ticket-console-head { min-height: 82px; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding: 13px 16px; }
  .ticket-console-mark { width: 42px; height: 42px; flex-basis: 42px; }
  .ticket-console-head .ticket-console-identity p { font-size: 9px; }
  .ticket-console-head .ticket-console-identity h2 { font-size: 24px; }
  .ticket-summary-cards { display: none; }
  .ticket-new-button { min-height: 48px; padding: 0 17px; }
  .ticket-console-toolbar { grid-template-columns: minmax(0, 1fr) auto; gap: 10px; padding: 12px 14px; }
  .ticket-console-toolbar .ticket-filter-search { grid-column: 1 / -1; }
  .ticket-console-toolbar .ticket-filter-tabs { min-width: 0; }
  .ticket-console-toolbar .ticket-filter-controls { min-width: 150px; }
  .ticket-console-toolbar .ticket-filter-result { grid-column: 1 / -1; justify-content: space-between; }
  .ticket-console-grid { min-height: 0; grid-template-columns: minmax(0, 1fr); }
  .ticket-console[data-mobile-view="list"] .ticket-detail-panel { display: none; }
  .ticket-console[data-mobile-view="detail"] > .ticket-console-head,
  .ticket-console[data-mobile-view="detail"] > .ticket-console-toolbar,
  .ticket-console[data-mobile-view="detail"] .ticket-list-panel { display: none; }
  .ticket-console[data-mobile-view="detail"] .ticket-detail-panel { display: block; height: 100%; }
  .ticket-list-panel { border: 0; }
  .ticket-list { max-height: none; }
  .ticket-detail:not([hidden]) { height: 100%; }
  .ticket-detail-head { display: grid; min-height: auto; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; padding: 14px 18px 17px; }
  .ticket-mobile-back { display: inline-flex; grid-column: 1 / -1; align-items: center; gap: 8px; width: max-content; min-height: 40px; padding: 0 11px; border: 1px solid rgba(168, 186, 56, .3); border-radius: 6px; background: #1a2012; color: #dce69d; cursor: pointer; font-size: 10px; font-weight: 900; letter-spacing: .05em; }
  .ticket-detail-head > div:last-child { align-self: end; }
  .ticket-detail-meta { padding: 12px 18px; }
  .ticket-thread { padding: 22px 18px; }
  .ticket-message { width: 90%; }
  .ticket-closed-actions { grid-template-columns: auto minmax(0, 1fr); padding: 17px 18px; }
  .ticket-closed-actions button { grid-column: 1 / -1; justify-content: center; }
  .ticket-reply-form { padding: 16px 18px 18px; }
}

@media (max-width: 560px) {
  .ticket-main { padding-bottom: 0; }
  .ticket-console-head { padding: 12px 14px; }
  .ticket-console-identity { gap: 10px; }
  .ticket-console-mark { width: 40px; height: 40px; flex-basis: 40px; }
  .ticket-new-button { width: auto; min-width: 48px; padding: 0 14px; }
  .ticket-new-button span { display: inline; }
  .ticket-console-toolbar { grid-template-columns: minmax(0, 1fr); }
  .ticket-console-toolbar .ticket-filter-tabs,
  .ticket-console-toolbar .ticket-filter-controls,
  .ticket-console-toolbar .ticket-filter-result { grid-column: 1; }
  .ticket-console-toolbar .ticket-filter-controls { min-width: 0; }
  .ticket-console-toolbar .ticket-filter-result { align-items: flex-start; flex-direction: column; }
  .ticket-list-panel > header { min-height: 60px; padding: 0 17px; }
  .ticket-list-item { padding: 19px 18px; }
  .ticket-list-item h3 { font-size: 22px; white-space: normal; }
  .ticket-list-item footer { align-items: flex-start; flex-direction: column; }
  .ticket-detail-head { align-items: start; grid-template-columns: minmax(0, 1fr); }
  .ticket-detail-head > div:last-child { justify-content: flex-start; }
  .ticket-detail-head h3 { font-size: 26px; }
  .ticket-detail-meta { gap: 8px 13px; font-size: 11px; }
  .ticket-message { width: 96%; }
  .ticket-message p { padding: 14px 15px; font-size: 14px; }
  .ticket-reply-form > div { align-items: stretch; }
  .ticket-closed-actions { grid-template-columns: minmax(0, 1fr); }
  .ticket-closed-actions > i { display: none; }
  .ticket-create-dialog form { padding: 28px 20px; }
  .ticket-reopen-note { font-size: 14px; }
}
