/* EZZY IT Softphone — visual polish only. No SIP, call, or audio logic lives here. */
:root {
  --ui-surface: #111a2d;
  --ui-surface-raised: #17243b;
  --ui-control: #0b1426;
  --ui-control-raised: #182640;
  --ui-border-soft: rgba(147, 166, 203, .16);
  --ui-focus: rgba(110, 155, 255, .24);
  --ui-radius-card: 22px;
  --ui-radius-control: 13px;
}
html[data-theme="light"] {
  --ui-surface: #ffffff;
  --ui-surface-raised: #f7f9fd;
  --ui-control: #f6f8fc;
  --ui-control-raised: #edf2fb;
  --ui-border-soft: rgba(69, 91, 132, .14);
  --ui-focus: rgba(66, 111, 229, .18);
}

html { min-height: 100%; }
body {
  min-height: 100vh;
  font-size: 13px;
  letter-spacing: .01em;
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}
button, input, select { -webkit-tap-highlight-color: transparent; }
button { transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .12s ease, filter .16s ease; }
button:focus-visible, input:focus-visible, select:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--ui-focus) !important;
}
button:disabled { opacity: .52; cursor: not-allowed; transform: none; }

.wp-shell { width: min(1260px, calc(100% - 48px)); margin: 22px auto 28px; }
.wp-header { margin-bottom: 22px; padding: 8px 4px 16px; border-bottom: 1px solid var(--ui-border-soft); }
.brand { gap: 14px; }
.brand-mark {
  width: 46px; height: 46px; border-radius: 15px;
  border: 1px solid rgba(255,255,255,.18);
  box-shadow: 0 7px 20px rgba(73, 108, 220, .22), inset 0 1px rgba(255,255,255,.28);
  letter-spacing: -.04em;
}
.brand h1 { font-size: 20px; line-height: 1.25; letter-spacing: -.035em; }
.brand p { font-size: 12px; letter-spacing: .015em; }
.header-actions { gap: 10px; }
.status-pill { min-height: 36px; padding: 8px 12px; box-shadow: 0 2px 7px rgba(0,0,0,.04); }
.theme-toggle { min-height: 36px; border-radius: 11px; }

.wp-card {
  border-radius: var(--ui-radius-card);
  border-color: var(--ui-border-soft);
  box-shadow: 0 16px 44px rgba(0,0,0,.12), inset 0 1px rgba(255,255,255,.025);
  backdrop-filter: blur(12px);
}
.setup { max-width: 690px; margin: 38px auto 46px; }
.setup .card-body { padding: 34px 36px 36px; }
.setup h2 { font-size: 25px; line-height: 1.25; letter-spacing: -.04em; }
.setup .muted { line-height: 1.6; }
.field { margin: 17px 0; }
.field label { font-size: 11px; font-weight: 750; letter-spacing: .055em; text-transform: uppercase; }
.field input, .field select, .settings-section select {
  min-height: 46px; border-radius: 12px; padding: 12px 14px;
  box-shadow: inset 0 1px 2px rgba(0,0,0,.025);
}
.field input:focus, .field select:focus, .settings-section select:focus {
  border-color: var(--wp-accent); box-shadow: 0 0 0 3px var(--ui-focus);
}
.row2 { gap: 15px; }
.check { margin: 18px 0 20px; line-height: 1.4; }
.check input { width: 15px; height: 15px; }
.primary { min-height: 46px; border-radius: 12px; letter-spacing: .01em; box-shadow: 0 8px 20px rgba(80, 110, 220, .16); }
.primary:hover { filter: brightness(1.06); box-shadow: 0 10px 24px rgba(80, 110, 220, .22); }
.secondary, .clear-btn { min-height: 36px; border-radius: 11px; }

.phone-grid { grid-template-columns: 330px minmax(0, 1fr); gap: 16px; align-items: stretch; }
.account-card { padding: 20px; }
.account-line { min-height: 34px; }
.account-name { font-size: 14px; letter-spacing: -.01em; }
.number-display {
  min-height: 76px; margin: 19px 0 14px; border-radius: 15px;
  font-size: 28px; font-weight: 550; letter-spacing: .025em;
  box-shadow: inset 0 2px 7px rgba(0,0,0,.07);
}
.dialpad { gap: 9px; }
.dial-key {
  min-height: 59px; border-radius: 14px; font-size: 21px;
  box-shadow: inset 0 1px rgba(255,255,255,.035), 0 2px 4px rgba(0,0,0,.04);
}
.dial-key:hover { transform: translateY(-1px); border-color: var(--wp-accent); }
.dial-key:active { transform: translateY(0) scale(.985); }
.dial-actions { gap: 9px; margin-top: 12px; }
.call-btn { min-height: 45px; border-radius: 13px; box-shadow: 0 5px 14px rgba(30, 190, 135, .12); }
.clear-btn { min-height: 45px; }

.call-screen { min-height: 555px; border-radius: var(--ui-radius-card); }
.call-top { min-height: 70px; padding: 18px 22px; }
.call-top strong { font-size: 14px; letter-spacing: -.01em; }
.call-state { margin-top: 5px; line-height: 1.45; }
.call-main { padding: 34px 24px; }
.avatar {
  width: 94px; height: 94px; border-radius: 29px; margin-bottom: 20px;
  border: 1px solid rgba(255,255,255,.17);
  box-shadow: 0 13px 32px rgba(73, 108, 220, .19), inset 0 1px rgba(255,255,255,.2);
}
.peer { font-size: 30px; line-height: 1.2; overflow-wrap: anywhere; }
.timer { margin-top: 10px; font-size: 13px; font-weight: 650; letter-spacing: .06em; }
.incoming-actions, .call-controls { gap: 9px; padding: 17px 20px 20px; }
.ctrl { min-height: 42px; border-radius: 12px; padding: 10px 14px; font-size: 12px; font-weight: 700; }
.ctrl:hover { border-color: var(--wp-accent); }
.ctrl.active { box-shadow: inset 0 0 0 1px rgba(110,155,255,.14); }

.phone-grid > aside[style*="grid-column"] { padding: 19px 20px 21px; }
.tabs { gap: 5px; padding: 4px; margin-bottom: 15px; border-radius: 12px; }
.tab { min-height: 36px; padding: 9px 12px; border-radius: 9px; font-size: 12px; font-weight: 700; }
.recent-list { max-height: 270px; gap: 8px; padding: 1px 3px 1px 1px; }
.recent-item { min-height: 62px; padding: 12px 14px; border-radius: 12px; transition: border-color .15s ease, transform .15s ease; }
.recent-item:hover { border-color: rgba(110,155,255,.48); }
.recent-item strong { font-size: 13px; letter-spacing: .005em; }
.recent-item small { font-size: 11px; line-height: 1.45; }
.recent-status { font-size: 11px; letter-spacing: .015em; }
.settings-grid { gap: 12px; }
.settings-section { border-radius: 14px; padding: 15px; }
.settings-section h3 { font-size: 12px; letter-spacing: .045em; text-transform: uppercase; }
.settings-section select { margin-top: 2px; }
.footer { margin: 18px 0 0; font-size: 11px; letter-spacing: .035em; }
.toast { border-radius: 13px; padding: 12px 15px; }

/* Native-feeling scrollbars, without changing the content or call-history logic. */
* { scrollbar-width: thin; scrollbar-color: rgba(133,153,190,.4) transparent; }
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb { background: rgba(133,153,190,.34); border-radius: 999px; border: 2px solid transparent; background-clip: padding-box; }

html[data-theme="light"] .wp-card { box-shadow: 0 14px 38px rgba(29,45,78,.075), inset 0 1px rgba(255,255,255,.9) !important; }
html[data-theme="light"] .wp-header { border-bottom-color: rgba(69,91,132,.12); }
html[data-theme="light"] .number-display { box-shadow: inset 0 2px 6px rgba(34,53,91,.045) !important; }
html[data-theme="light"] .dial-key { box-shadow: 0 2px 5px rgba(34,53,91,.05) !important; }
html[data-theme="light"] .call-btn { box-shadow: 0 5px 14px rgba(30,150,105,.12); }
html[data-theme="light"] .recent-item:hover { border-color: rgba(66,111,229,.38) !important; }
html[data-theme="light"] .setup .muted { color: #69758a; }

@media (min-width: 1200px) {
  .phone-grid { grid-template-columns: 330px minmax(0, 1fr); }
  .call-screen { min-height: 570px; }
}
@media (max-width: 900px) {
  .wp-shell { width: min(100% - 28px, 760px); margin-top: 16px; }
  .phone-grid { grid-template-columns: 1fr; }
  .call-screen { min-height: 440px; }
  .phone-grid > aside[style*="grid-column"] { grid-column: auto !important; }
}
@media (max-width: 600px) {
  .wp-shell { width: calc(100% - 20px); margin-top: 10px; }
  .wp-header { align-items: flex-start; gap: 12px; padding: 4px 0 13px; margin-bottom: 16px; }
  .brand { gap: 10px; }
  .brand-mark { width: 40px; height: 40px; border-radius: 13px; font-size: 19px; }
  .brand h1 { font-size: 17px; }
  .brand p { font-size: 11px; }
  .header-actions { flex-direction: column-reverse; align-items: flex-end; gap: 7px; }
  .status-pill { min-height: 30px; padding: 6px 9px; font-size: 10px; }
  .theme-toggle { min-height: 32px; padding: 7px 9px; font-size: 11px; }
  .setup { margin: 22px auto 30px; }
  .setup .card-body { padding: 24px 20px 22px; }
  .setup h2 { font-size: 22px; }
  .row2 { grid-template-columns: 1fr; gap: 0; }
  .account-card { padding: 15px; }
  .number-display { min-height: 66px; font-size: 25px; }
  .dial-key { min-height: 55px; }
  .call-screen { min-height: 400px; }
  .call-top { padding: 15px 16px; }
  .call-main { padding: 24px 15px; }
  .avatar { width: 78px; height: 78px; border-radius: 25px; font-size: 29px; }
  .peer { font-size: 24px; }
  .incoming-actions, .call-controls { padding: 13px; gap: 7px; }
  .ctrl { min-width: 74px; padding: 10px 11px; }
  .phone-grid > aside[style*="grid-column"] { padding: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
