:root {
  --funify-page-width: min(1800px, calc(100% - 64px));
  --brand: var(--gh-accent);
  --surface: var(--panel);
  --text: var(--ink-strong);
  --muted: var(--ink-soft);
  --border: var(--line);
  --clock-paper: #eef4ff;
  --clock-text: #1f2937;
  --clock-shadow: 0 12px 28px rgba(15, 23, 42, 0.1);
  --clock-control-bg: rgba(255, 255, 255, 0.62);
  --clock-control-bg-hover: rgba(255, 255, 255, 0.84);
}

[data-theme='dark'] {
  --clock-paper: #1d2840;
  --clock-text: #e5eefc;
  --clock-shadow: 0 14px 30px rgba(0, 0, 0, 0.28);
  --clock-control-bg: rgba(15, 23, 42, 0.48);
  --clock-control-bg-hover: rgba(15, 23, 42, 0.72);
}

.calculator-page {
  width: min(1440px, calc(100% - 32px));
}

.calculator-grid {
  grid-template-columns: minmax(0, 1fr);
}

.calculator-main {
  min-width: 0;
}

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 12px;
  font-weight: 700;
  border: 1px solid var(--line);
  cursor: pointer;
  text-decoration: none;
  transition:
    border-color 0.18s ease,
    background 0.18s ease,
    color 0.18s ease,
    transform 0.18s ease;
}

.btn-primary {
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
}

.btn-primary:hover {
  transform: translateY(-1px);
  filter: brightness(1.02);
}

.btn-ghost {
  color: var(--ink-strong);
  background: var(--panel-strong);
}

.btn-ghost:hover {
  color: var(--brand);
  border-color: color-mix(in oklab, var(--brand), transparent 62%);
  background: var(--brand-soft);
}

.time-panel .tool-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.time-panel .tool-title {
  margin: 0 0 6px;
  font-size: 1.35rem;
  line-height: 1.25;
  color: var(--ink-strong);
}

.time-panel .tool-lead {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.7;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 20px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-soft);
  color: var(--ink-soft);
  padding: 6px 10px;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.2;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--brand), transparent 84%);
}

.tool-form,
.tool-workspace {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tool-form {
  overflow: visible;
}

.time-actions-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.city-search-field {
  min-width: 0;
  position: relative;
}

.city-search-field label {
  display: block;
  margin-bottom: 6px;
  font-weight: 700;
  color: var(--ink-strong);
}

.city-search-field input[type='text'] {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel-strong);
  color: var(--ink-strong);
  padding: 0 12px;
}

.city-suggestion-list {
  position: absolute;
  left: 0;
  top: calc(100% + 6px);
  z-index: 10000;
  display: none;
  width: min(420px, calc(100vw - 48px));
  min-width: min(100%, 320px);
  max-height: 336px;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px;
  border: 1px solid #dce7f3;
  border-radius: 18px;
  background: linear-gradient(145deg, #ffffff 0%, #fbfdff 100%);
  box-shadow: 0 18px 42px rgba(37, 65, 102, 0.16);
  backdrop-filter: blur(12px);
  overscroll-behavior: contain;
}

.city-suggestion-list.active {
  display: block;
}

.city-suggestion-option {
  width: 100%;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 9px 10px;
  border: 0;
  border-radius: 13px;
  border-bottom: 0;
  background: transparent;
  color: var(--ink-strong);
  text-align: left;
  cursor: pointer;
  white-space: normal;
  transition:
    background 0.16s ease,
    color 0.16s ease,
    transform 0.16s ease,
    box-shadow 0.16s ease;
}

.city-suggestion-option + .city-suggestion-option {
  margin-top: 3px;
}

.city-suggestion-option:hover,
.city-suggestion-option:focus {
  background: linear-gradient(135deg, #eaf4ff 0%, #ecfbf7 100%);
  color: #135ab8;
  box-shadow: inset 0 0 0 1px #cfe2ff;
  transform: translateY(-1px);
  outline: none;
}

.city-suggestion-pin {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(180deg, var(--time-blue), var(--time-teal));
  box-shadow: 0 6px 14px rgba(47, 128, 237, 0.18);
  position: relative;
  overflow: hidden;
}

.city-suggestion-pin::before {
  content: '';
  width: 16px;
  height: 20px;
  display: block;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='white' d='M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7z'/%3E%3Ccircle cx='12' cy='9' r='2.7' fill='%232f80ed'/%3E%3C/svg%3E")
    center / contain no-repeat;
}

.city-suggestion-pin::after {
  content: none;
}

.city-suggestion-text {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.city-suggestion-name {
  min-width: 0;
  color: #182235;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.city-suggestion-country {
  min-width: 0;
  color: #667085;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.city-suggestion-option:hover .city-suggestion-name,
.city-suggestion-option:focus .city-suggestion-name {
  color: #135ab8;
}

.city-suggestion-option:hover .city-suggestion-country,
.city-suggestion-option:focus .city-suggestion-country {
  color: #0f766e;
}

.city-suggestion-option.manual-location-option {
  grid-template-columns: 28px minmax(0, 1fr);
  margin-top: 7px;
  border-top: 1px solid #dce7f3;
  border-radius: 0 0 11px 11px;
  padding-top: 11px;
}

.manual-location-option .city-suggestion-pin {
  background: linear-gradient(180deg, #64748b, #475569);
}

.manual-location-option .city-suggestion-pin::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 2px;
  border-radius: 2px;
  background: #fff;
  transform: translate(-50%, -50%);
}

.manual-location-option .city-suggestion-pin::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 2px;
  height: 12px;
  border-radius: 2px;
  background: #fff;
  transform: translate(-50%, -50%);
}

[data-theme='dark'] .city-suggestion-option.manual-location-option {
  border-top-color: #33465f;
}

.city-suggestion-list::-webkit-scrollbar {
  width: 8px;
}

.city-suggestion-list::-webkit-scrollbar-track {
  background: transparent;
}

.city-suggestion-list::-webkit-scrollbar-thumb {
  border: 2px solid #fff;
  border-radius: 999px;
  background: #bfd1e6;
}

.time-controls {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  gap: 10px;
}

.time-controls .btn-primary,
.time-controls .btn-ghost {
  min-width: 110px;
  white-space: nowrap;
}

.clock-board-shell {
  background: transparent;
  border-radius: 6px;
  padding: 0;
  position: relative;
  overflow: visible;
}

.widget-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px;
  align-items: start;
  padding-top: 8px;
  min-height: 320px;
}

.clock-box {
  --clock-accent: #8ec5f4;
  position: relative;
  display: grid;
  grid-template-rows: 62px minmax(90px, 1fr) 54px;
  min-height: 206px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 14px;
  background:
    radial-gradient(
      circle at 78% 18%,
      color-mix(in oklab, var(--clock-accent), white 22%) 0,
      transparent 30%
    ),
    linear-gradient(
      155deg,
      color-mix(in oklab, var(--clock-accent), white 18%) 0%,
      var(--clock-accent) 48%,
      color-mix(in oklab, var(--clock-accent), black 22%) 100%
    );
  background-clip: padding-box;
  color: #fff;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.14);
  cursor: grab;
  overflow: hidden;
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease;
  isolation: isolate;
  font-family:
    'SF Pro Display',
    'SF Pro Text',
    'Segoe UI Variable',
    'Segoe UI',
    Inter,
    Roboto,
    'Helvetica Neue',
    Arial,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    sans-serif;
}

.clock-box::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 6;
  pointer-events: none;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: inherit;
}

.clock-box:hover {
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.12);
}

body.time-touch-sorting {
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
}

.clock-box.is-touch-dragging {
  position: fixed !important;
  z-index: 10030 !important;
  pointer-events: none;
  cursor: grabbing;
  box-shadow: 0 26px 58px rgba(15, 23, 42, 0.32) !important;
  transform: scale(1.035) rotate(-0.35deg);
  transition: none !important;
}

.clock-drag-placeholder {
  min-height: 206px;
  border-radius: 18px;
  border: 2px dashed rgba(47, 128, 237, 0.45);
  background: rgba(47, 128, 237, 0.08);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.clock-box:has(.settings-panel.active) {
  z-index: 30;
  overflow: visible;
}

.clock-box:has(.settings-panel.active) .metric-bar {
  border-radius: 0 0 13px 13px;
}

.widget-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px;
  height: 62px;
  min-height: 62px;
  padding: 13px 15px 4px;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.widget-title {
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

.widget-actions {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  flex: 0 0 auto;
}

.clock-box .close-btn,
.clock-box .settings-btn {
  position: static;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: var(--card-control-color, currentColor);
  opacity: 1;
  cursor: pointer;
  transition:
    background 0.18s ease,
    transform 0.18s ease;
  user-select: none;
  backdrop-filter: blur(8px);
  font-size: 0;
}

.clock-box .close-btn::before,
.clock-box .settings-btn::before {
  content: none;
}

.clock-box .settings-btn svg,
.clock-box .close-btn svg {
  width: 12px;
  height: 12px;
  display: block;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.clock-box .close-btn:hover,
.clock-box .settings-btn:hover {
  opacity: 1;
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.3);
}

.clock-box .settings-panel {
  position: absolute;
  left: calc(100% + 12px);
  right: auto;
  top: 0;
  z-index: 40;
  display: none;
  width: min(306px, calc(100vw - 32px));
  max-height: min(78vh, 480px);
  overflow: auto;
  padding: 8px;
  border: 1px solid var(--color-border);
  border-radius: 14px;
  background: var(--color-surface);
  color: #1f2937;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.22);
}

.clock-box.settings-panel-open-left .settings-panel {
  left: auto;
  right: calc(100% + 12px);
}

.clock-box.settings-panel-open-below .settings-panel {
  left: 0;
  right: auto;
  top: calc(100% + 10px);
}

[data-theme='dark'] .clock-box .settings-panel {
  background: var(--color-surface);
  border-color: var(--color-border);
  color: #e5eefc;
}

.clock-box .settings-panel.active {
  display: block;
}

.clock-box .settings-panel label {
  margin: 0;
}

.settings-panel-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
  padding: 0 1px 6px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.1);
}

.settings-panel-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  align-self: center;
  padding: 0;
}

.settings-check {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 22px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #334155;
  font-size: 9.5px;
  font-weight: 820;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.settings-check input {
  width: 13px;
  height: 13px;
  min-width: 13px;
  min-height: 13px;
  max-width: 13px;
  max-height: 13px;
  margin: 0;
  accent-color: var(--brand);
}

.settings-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #334155;
  font-size: 9.5px;
  font-weight: 820;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.settings-action-btn:hover,
.settings-action-btn:focus-visible {
  color: var(--brand);
  text-decoration: underline;
  outline: none;
}

[data-theme='dark'] .settings-check {
  color: #dbeafe;
}

[data-theme='dark'] .settings-action-btn {
  color: #dbeafe;
}

[data-theme='dark'] .settings-panel-header {
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

.settings-panel-heading {
  min-width: 0;
}

.settings-panel-title {
  display: block;
  color: #0f172a;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.1;
}

[data-theme='dark'] .settings-panel-title {
  color: #f8fafc;
}

.settings-section {
  padding: 6px;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  background: var(--color-background);
}

.settings-section + .settings-section {
  margin-top: 4px;
}

[data-theme='dark'] .settings-section {
  background: var(--color-background);
  border-color: var(--color-border);
}

.settings-section-title {
  margin-bottom: 4px;
  color: #334155;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.035em;
  text-transform: uppercase;
}

[data-theme='dark'] .settings-section-title {
  color: #cbd5e1;
}

.settings-color-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 3px;
}

.clock-box .color-picker {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 5px;
  min-width: 0;
  min-height: 27px;
  padding: 3px 4px 3px 6px;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  background: var(--color-surface);
  font-size: 10px;
  font-weight: 760;
  color: #1f2937;
}

.clock-box .color-picker span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

[data-theme='dark'] .clock-box .color-picker {
  background: var(--color-surface);
  border-color: var(--color-border);
  color: #e5eefc;
}

.clock-box input[type='color'] {
  width: 21px;
  height: 21px;
  min-width: 21px;
  min-height: 21px;
  max-width: 21px;
  max-height: 21px;
  padding: 2px;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  background: var(--color-surface);
  overflow: hidden;
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.clock-box input[type='color']::-webkit-color-swatch-wrapper {
  padding: 0;
}

.clock-box input[type='color']::-webkit-color-swatch {
  border: 0;
  border-radius: 2px;
}

.clock-box input[type='color']::-moz-color-swatch {
  border: 0;
  border-radius: 2px;
}

.clock-box input[type='color']:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.clock-box .unit-settings {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin-top: 0;
}

.clock-box .unit-setting {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  min-height: 27px;
  padding: 3px 5px 3px 6px;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  background: var(--color-surface);
  font-size: 10px;
  font-weight: 760;
}

[data-theme='dark'] .clock-box .unit-setting {
  background: var(--color-surface);
  border-color: var(--color-border);
}

.clock-box .unit-toggle {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  width: 62px;
  height: 21px;
  padding: 2px;
  border-radius: 6px;
  background: #d9e1ec;
  color: #526072;
  cursor: pointer;
  isolation: isolate;
}

.clock-box .unit-toggle::before {
  content: '';
  position: absolute;
  z-index: -1;
  top: 2px;
  left: 2px;
  width: 29px;
  height: 17px;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.18);
  transition: transform 0.18s ease;
}

.clock-box .unit-toggle:has(input:checked)::before {
  transform: translateX(31px);
}

.clock-box .unit-toggle input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  opacity: 0;
  pointer-events: none;
}

.clock-box .unit-toggle span {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  line-height: 1;
  transition: color 0.18s ease;
}

.clock-box .unit-toggle span:first-of-type,
.clock-box .unit-toggle:has(input:checked) span:last-of-type {
  color: #1f2937;
}

.clock-box .unit-toggle:has(input:checked) span:first-of-type {
  color: #526072;
}

.clock-box .unit-toggle:focus-within {
  outline: 2px solid #3861fb;
  outline-offset: 2px;
}

.clock-box .country {
  margin: 0;
  color: var(--card-country-color, currentColor);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.15;
  opacity: 0.92;
  letter-spacing: -0.01em;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.clock-box .city {
  margin-top: 3px;
  color: var(--card-city-color, currentColor);
  font-size: 17.5px;
  font-weight: 780;
  line-height: 1.18;
  letter-spacing: -0.01em;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  display: block;
  text-overflow: ellipsis;
  max-width: 100%;
  max-height: 25px;
}

.clock-box[data-manual-card='true'] .widget-title {
  cursor: text;
}

.manual-title-edit {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 8;
  width: min(210px, calc(100% - 36px));
  display: grid;
  gap: 7px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.24);
  backdrop-filter: blur(12px);
  transform: translate(-50%, -50%);
}

.manual-title-edit input {
  width: 100%;
  min-width: 0;
  height: 34px;
  box-sizing: border-box;
  border: 1px solid rgba(24, 42, 72, 0.16);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.96);
  color: #102036;
  font: inherit;
  font-size: 13px;
  font-weight: 760;
  padding: 0 10px;
  outline: none;
}

.manual-title-edit input:focus {
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(47, 128, 237, 0.35);
}

.manual-title-edit .manual-city-input {
  font-size: 14px;
  font-weight: 820;
}

.manual-title-edit-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}

.manual-title-edit-actions button {
  min-width: 52px;
  height: 24px;
  border: 0;
  border-radius: 999px;
  padding: 0 10px;
  font-size: 11px;
  font-weight: 850;
  cursor: pointer;
}

.manual-title-cancel {
  background: rgba(15, 23, 42, 0.08);
  color: #334155;
}

.manual-title-save {
  background: #1769d8;
  color: #fff;
}

.widget-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 84px;
  align-items: center;
  gap: 12px;
  min-height: 90px;
  padding: 2px 17px 8px;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.time-wrap {
  min-width: 0;
}

.clock-box .time {
  margin: 0;
  color: var(--card-clock-color, currentColor);
  font-size: 42px;
  line-height: 0.94;
  font-weight: 760;
  letter-spacing: -0.055em;
  font-variant-numeric: tabular-nums;
  text-align: left;
}

.clock-box .time-period {
  margin-left: 4px;
  font-size: 12px;
  line-height: 1;
  font-weight: 760;
  letter-spacing: 0;
  vertical-align: baseline;
  opacity: 0.9;
}

.date-line {
  display: flex;
  color: var(--card-date-color, currentColor);
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  font-size: 11px;
  line-height: 1;
  font-weight: 620;
  opacity: 0.95;
  white-space: nowrap;
}

.timezone-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 17px;
  padding: 0 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: inherit;
  font-size: 10px;
  line-height: 1;
  font-weight: 760;
  letter-spacing: 0.01em;
}

.weather-block {
  width: 84px;
  min-width: 84px;
  max-width: 84px;
  height: 76px;
  display: grid;
  grid-template-rows: 44px auto auto;
  justify-items: center;
  align-items: center;
  align-self: center;
  justify-self: end;
  text-align: center;
  transform: none;
  overflow: visible;
}

.weather-icon {
  width: 64px;
  height: 44px;
  display: block;
  margin: 0 auto 3px;
  color: var(--card-weather-icon-color, currentColor);
}

.weather-icon svg {
  display: block;
  width: 64px;
  height: 44px;
  overflow: visible;
}

.weather-condition {
  margin: 0;
  max-width: 84px;
  color: var(--card-weather-state-color, currentColor);
  font-size: 12px;
  line-height: 1.05;
  font-weight: 740;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.015em;
}

.weather-temp,
.clock-box .temperature {
  margin-top: 3px;
  color: var(--card-temperature-color, currentColor);
  font-size: 16px;
  line-height: 1;
  font-weight: 760;
  text-align: center;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.metric-bar {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  height: 54px;
  background: linear-gradient(
    180deg,
    color-mix(in oklab, var(--metric-bg, #123b7a), white 6%),
    color-mix(in oklab, var(--metric-bg, #123b7a), black 12%)
  );
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
  position: relative;
  z-index: 1;
}

.metric-item {
  position: relative;
  min-width: 0;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 4px;
  padding: 8px 5px;
  text-align: center;
}

.metric-item + .metric-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 1px;
  background: rgba(255, 255, 255, 0.18);
}

.metric-head {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
  font-size: 9.5px;
  line-height: 1;
  font-weight: 620;
  opacity: 0.94;
  white-space: nowrap;
}

.metric-icon {
  width: 11px;
  height: 11px;
  flex: 0 0 auto;
  display: inline-flex;
}

.metric-icon svg {
  width: 11px;
  height: 11px;
  display: block;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.95;
}

.metric-value {
  display: block;
  font-size: 14px;
  line-height: 1;
  font-weight: 760;
  letter-spacing: -0.025em;
  white-space: nowrap;
}

.weather-status .metric-head {
  color: var(--card-wind-title-color, currentColor);
}

.weather-status .metric-value {
  color: var(--card-wind-value-color, currentColor);
}

.precipitation .metric-head {
  color: var(--card-precipitation-title-color, currentColor);
}

.precipitation .metric-value {
  color: var(--card-precipitation-value-color, currentColor);
}

.feels-like .metric-head {
  color: var(--card-feels-like-title-color, currentColor);
}

.feels-like .metric-value {
  color: var(--card-feels-like-value-color, currentColor);
}

.clock-box .weather-status,
.clock-box .precipitation {
  text-align: center;
  font-size: 0.92rem;
  line-height: 1.45;
  opacity: 0.92;
}

.ui-autocomplete {
  z-index: 9999 !important;
  max-height: 300px;
  overflow-y: auto;
  overflow-x: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  color: var(--ink-strong);
  box-shadow: var(--shadow-md);
}

.ui-menu .ui-menu-item-wrapper {
  padding: 8px 10px;
}

.tool-note,
.tool-reference-note {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.7;
}

.result-preview {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 16px;
  padding: 14px;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.06);
}

.result-header-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 10px;
  width: 100%;
}

.result-title {
  margin: 0;
  min-width: 0;
  text-align: left;
  font-size: 1rem;
  line-height: 1.35;
  color: var(--text);
}

.plain-icon-btn {
  all: unset !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 32px !important;
  border: 1px solid var(--border) !important;
  border-radius: 999px !important;
  padding: 0 12px !important;
  background: var(--panel-soft) !important;
  cursor: pointer !important;
  color: var(--muted) !important;
  font-size: 0.88rem !important;
  font-weight: 700 !important;
  line-height: 1 !important;
}

.plain-icon-btn:hover {
  border-color: var(--brand) !important;
  color: var(--brand) !important;
  background: color-mix(in oklab, var(--brand), transparent 92%) !important;
}

#reset-button.reset-group-btn {
  gap: 6px !important;
  min-height: 34px !important;
  padding: 0 12px 0 10px !important;
  border-color: #dce7f3 !important;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%) !important;
  color: #526072 !important;
  box-shadow: 0 6px 14px rgba(37, 65, 102, 0.07) !important;
  transition:
    border-color 0.16s ease,
    background 0.16s ease,
    color 0.16s ease,
    box-shadow 0.16s ease,
    transform 0.16s ease !important;
}

#reset-button.reset-group-btn .reset-group-icon {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #eef6ff;
  color: #2f80ed;
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
}

#reset-button.reset-group-btn:hover {
  transform: translateY(-1px);
  border-color: #ffc9c9 !important;
  background: linear-gradient(180deg, #fffafa 0%, #fff1f1 100%) !important;
  color: #d92d20 !important;
  box-shadow: 0 8px 18px rgba(217, 45, 32, 0.1) !important;
}

#reset-button.reset-group-btn:hover .reset-group-icon {
  background: #ffe4e4;
  color: #d92d20;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.stat-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  background: var(--panel-soft);
}

.stat-card .k {
  display: block;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.3;
}

.stat-card .v {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 1.08rem;
  font-weight: 800;
}

.stat-card .v.non-zero {
  color: #ff4fb3;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.result-preview .result-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel-soft);
}

.result-preview .result-item .label {
  color: var(--muted);
  font-size: 0.9rem;
  flex: 0 0 auto;
}

.result-preview .result-item .value {
  color: var(--text);
  font-weight: 700;
  text-align: right;
  word-break: break-word;
  min-width: 0;
}

.feature-pill-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
}

.step-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.feature-pill,
.step-card,
.info-card,
.side-box {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  background: var(--panel-soft);
}

.feature-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 0.9rem;
  font-weight: 700;
}

.feature-pill::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--brand), transparent 84%);
}

.step-card h3,
.info-card h3,
.side-box h3 {
  margin: 0 0 8px;
  color: var(--ink-strong);
  font-size: 1rem;
}

.step-card p,
.info-card p,
.side-box p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.65;
}

.time-lower-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.time-lower-main {
  width: 100%;
  max-width: 100%;
}

.time-lower-main {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.tip-list {
  display: grid;
  gap: 10px;
}

.tip-item {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 10px;
  align-items: flex-start;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: color-mix(in oklab, var(--surface), white 3%);
}

.tip-icon {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-weight: 800;
}

.tone-blue {
  background: rgba(56, 97, 251, 0.12);
}

.tone-violet {
  background: rgba(124, 58, 237, 0.12);
}

.tone-green {
  background: rgba(16, 185, 129, 0.12);
}

.tone-amber {
  background: rgba(245, 158, 11, 0.14);
}

.tip-body strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text);
}

.tip-body p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  font-size: 0.92rem;
}

.media-figure {
  display: grid;
  justify-items: center;
  gap: 8px;
  margin: 0 0 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-soft);
}

.media-figure img {
  width: min(100%, 720px);
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--line);
  object-fit: cover;
}

.media-figure figcaption {
  max-width: 760px;
  color: var(--ink-soft);
  font-size: 0.9rem;
  text-align: center;
  line-height: 1.55;
}

.collapse {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.collapse + .collapse {
  margin-top: 10px;
}

.collapse summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  padding: 13px 14px;
  color: var(--ink-strong);
}

.collapse summary::-webkit-details-marker {
  display: none;
}

.collapse .content {
  border-top: 1px solid var(--line);
  padding: 12px 14px;
  color: var(--ink-soft);
  line-height: 1.7;
}

.collapse .content p {
  margin: 0;
}

.collapse[open] .caret::before {
  transform: rotate(-45deg);
}

.caret {
  width: 15px;
  height: 15px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  color: var(--brand);
  font-size: 0;
}

.caret::before {
  content: '';
  width: 7px;
  height: 7px;
  border-right: 2.5px solid currentColor;
  border-bottom: 2.5px solid currentColor;
  border-radius: 1px;
  transform: rotate(-45deg);
  transition: transform 0.18s ease;
}

body.time-fullscreen-mode funify-header,
body.time-fullscreen-mode funify-footer,
body.time-fullscreen-mode .scroll-top-button,
body.time-fullscreen-mode #tool .tool-lead,
body.time-fullscreen-mode #tool .pill-row {
  display: none !important;
}

body.time-fullscreen-mode #tool .city-search-field {
  display: none !important;
}

body.time-fullscreen-mode #tool .time-actions-bar {
  display: flex;
  justify-content: flex-end;
  margin-top: -44px;
  margin-bottom: 8px;
}

body.time-fullscreen-mode #tool .time-controls {
  display: flex;
}

body.time-fullscreen-mode #tool #reset-button {
  display: none !important;
}

body.time-fullscreen-mode {
  overflow: hidden;
  background: #f3f6fa;
}

body.time-fullscreen-mode .calculator-page {
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  padding: 0;
}

body.time-fullscreen-mode .calculator-grid {
  display: block;
  min-height: 100vh;
  min-height: 100dvh;
}

body.time-fullscreen-mode #tool {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  margin-bottom: 0;
  border: 0;
  border-radius: 0;
  background: #f3f6fa;
  box-shadow: none;
}

body.time-fullscreen-mode .tool-form,
body.time-fullscreen-mode .clock-board-shell {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  flex-direction: column;
}

body.time-fullscreen-mode .tool-form {
  gap: 0;
}

body.time-fullscreen-mode #clock-container {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.clock-box.ui-sortable-helper {
  opacity: 0.6;
  pointer-events: none;
  transform: none !important;
  cursor: grabbing;
  box-sizing: border-box;
}

.clock-box.ui-sortable-helper:hover {
  opacity: 0.6;
  transform: none !important;
}

@media (max-width: 1024px) {
  .clock-box {
    cursor: default;
    touch-action: pan-y;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
  }

  .clock-box button,
  .clock-box input,
  .clock-box label,
  .clock-box .settings-panel {
    touch-action: manipulation;
  }

  .time-lower-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .step-card-grid,
  .result-grid,
  .feature-pill-row {
    grid-template-columns: 1fr;
  }

  .time-actions-bar {
    grid-template-columns: 1fr;
    min-width: 0;
    gap: 10px;
  }

  .time-controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .time-controls .btn-primary,
  .time-controls .btn-ghost {
    min-width: 0;
    width: 100%;
  }

  .result-preview .result-item {
    display: block;
    min-height: 0;
  }

  .result-preview .result-item .label {
    display: block;
    margin-bottom: 4px;
  }

  .result-preview .result-item .value {
    text-align: left;
  }
}

:root {
  --time-bg: #f8fbff;
  --time-surface: rgba(255, 255, 255, 0.92);
  --time-surface-solid: #ffffff;
  --time-surface-soft: #f3f8ff;
  --time-line: #e4ebf6;
  --time-line-strong: #d8e2ef;
  --time-text: #0f172a;
  --time-text-soft: #344056;
  --time-muted: #667085;
  --time-blue: #2f80ed;
  --time-blue-soft: #eaf4ff;
  --time-teal: #13c2a3;
  --time-green: #17b26a;
  --time-orange: #ffb020;
  --time-red: #ff4d6d;
  --time-purple: #7b61ff;
  --time-shadow: 0 14px 35px rgba(16, 24, 40, 0.08);
  --time-shadow-soft: 0 8px 18px rgba(16, 24, 40, 0.055);
}

[data-theme='dark'] {
  --time-bg: #08111f;
  --time-surface: rgba(15, 23, 42, 0.94);
  --time-surface-solid: #0f172a;
  --time-surface-soft: #111c2d;
  --time-line: #26364c;
  --time-line-strong: #33465f;
  --time-text: #f1f5f9;
  --time-text-soft: #cbd5e1;
  --time-muted: #94a3b8;
  --time-blue-soft: rgba(47, 128, 237, 0.16);
  --time-shadow: 0 16px 38px rgba(0, 0, 0, 0.28);
  --time-shadow-soft: 0 9px 22px rgba(0, 0, 0, 0.22);
}

body {
  background:
    radial-gradient(circle at 22% -8%, rgba(47, 128, 237, 0.06), transparent 34%),
    radial-gradient(circle at 90% 6%, rgba(19, 194, 163, 0.07), transparent 32%),
    linear-gradient(180deg, #ffffff 0%, var(--time-bg) 38%, #ffffff 100%);
}

[data-theme='dark'] body {
  background:
    radial-gradient(circle at 20% -8%, rgba(47, 128, 237, 0.14), transparent 34%),
    radial-gradient(circle at 92% 5%, rgba(19, 194, 163, 0.1), transparent 30%),
    linear-gradient(180deg, #08111f 0%, #0b1422 42%, #08111f 100%);
  color: var(--time-text-soft);
}

.calculator-page.time-dashboard-page {
  width: var(--funify-page-width);
  margin: 32px auto 28px;
}

.calculator-grid.time-dashboard-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 28px;
  align-items: start;
}

.time-dashboard-main {
  min-width: 0;
}

.time-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.time-hero-copy {
  min-width: 0;
}

.time-hero-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 10px;
  color: var(--color-muted);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.08em;
}

.time-hero-live {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--color-text);
  letter-spacing: 0.04em;
}

.time-hero-live::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--time-green);
  content: '';
}

.time-hero-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 24px;
}

.time-hero-utc {
  display: grid;
  gap: 3px;
  color: var(--color-text);
  font-variant-numeric: tabular-nums;
}

.time-hero-utc > span {
  color: var(--color-muted);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.08em;
}

.time-hero-utc time {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.25;
}

.time-hero-description-mobile {
  display: none;
}

.time-hero h1 {
  margin: 0;
  font-size: clamp(28px, 2.6vw, 34px);
  line-height: 1.1;
  letter-spacing: -0.045em;
  color: var(--time-text);
}

.time-hero .subtitle {
  margin: 8px 0 0;
  color: #667085;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.time-toolbar {
  position: relative;
  z-index: 40;
  min-height: 70px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  margin-bottom: 22px;
  border: 1px solid var(--time-line);
  border-radius: 18px;
  background: var(--time-surface);
  box-shadow: var(--time-shadow-soft);
  backdrop-filter: blur(16px);
  overflow: visible;
}

.fullscreen-brand,
.fullscreen-toolbar-title,
.fullscreen-group-tabs {
  display: none;
}

.time-toolbar .city-search-field {
  position: relative;
  z-index: 2001;
  flex: 1 1 300px;
  max-width: 300px;
  min-width: 190px;
  height: 42px;
}

.search-box-shell {
  height: 42px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 18px;
  border: 1px solid var(--time-line-strong);
  border-radius: 16px;
  background: #fff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    0 7px 20px rgba(16, 24, 40, 0.04);
  color: #94a3b8;
  font-size: 14px;
  font-weight: 600;
}

.search-box-shell input[type='text'] {
  width: 100%;
  min-height: 0;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: var(--time-text);
  font-weight: 700;
  outline: none;
}

.search-box-shell input[type='text']::placeholder {
  color: #94a3b8;
}

.time-btn {
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 20px;
  border: 1px solid var(--time-line);
  border-radius: 16px;
  background: #fff;
  color: #182235;
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 7px 18px rgba(16, 24, 40, 0.04);
  white-space: nowrap;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease;
}

.time-btn:hover {
  transform: translateY(-1px);
}

.time-btn-primary {
  border-color: transparent;
  background: linear-gradient(180deg, #1cc8ad, #0fb49b);
  color: #fff;
  box-shadow: 0 12px 22px rgba(15, 180, 155, 0.26);
}

.time-btn-selected {
  border-color: #dbeafe;
  color: #1769d8;
  background: #eaf4ff;
}

#fullscreen-button {
  flex: 0 0 120px;
  width: 120px;
  height: 42px;
}

.group-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(100px, 1fr));
  flex: 1 1 auto;
  align-items: center;
  gap: 0;
  height: 42px;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-bottom: 1px solid #d7e1ec;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.group-tab {
  height: 42px;
  width: 100%;
  min-width: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #617086;
  font-size: 12px;
  font-weight: 760;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition:
    color 0.16s ease,
    background 0.16s ease,
    box-shadow 0.16s ease;
}

.group-tab:hover {
  color: #1769d8;
  background: rgba(226, 237, 250, 0.42);
}

.group-tab.active {
  background: transparent;
  color: #0f67d8;
  box-shadow: inset 0 -3px 0 #2f80ed;
}

[data-theme='dark'] .group-tabs {
  border-color: rgba(148, 163, 184, 0.24);
}

[data-theme='dark'] .group-tab {
  color: #aebed3;
}

[data-theme='dark'] .group-tab:hover {
  color: #bfdbfe;
  background: rgba(59, 130, 246, 0.12);
}

[data-theme='dark'] .group-tab.active {
  color: #eaf4ff;
  background: transparent;
  box-shadow: inset 0 -3px 0 #60a5fa;
}

.widget-grid.city-grid {
  --city-card-width: 300px;
  display: grid;
  grid-template-columns: repeat(
    auto-fit,
    minmax(min(var(--city-card-width), 100%), var(--city-card-width))
  );
  justify-content: center;
  justify-items: stretch;
  align-content: start;
  gap: 16px;
  padding-top: 0;
  min-height: 320px;
}

.widget-grid.city-grid .clock-box {
  grid-column: span 1;
  aspect-ratio: 1.36 / 1;
  min-height: 206px;
  border-radius: 18px;
  box-shadow: var(--time-shadow-soft);
}

.widget-grid.city-grid .clock-box.featured {
  grid-column: span 1;
}

.clock-box.group-hidden {
  display: none !important;
}

.clock-box .favorite-btn {
  position: static;
  border-radius: 999px;
  cursor: pointer;
  transition:
    background 0.18s ease,
    transform 0.18s ease,
    color 0.18s ease;
}

.clock-box .widget-actions {
  position: absolute;
  top: 4px;
  right: 6px;
  z-index: 5;
  gap: 2px;
  align-items: center;
}

.clock-box .widget-title {
  padding-top: 10px;
  padding-right: 20px;
}

.clock-box .favorite-btn,
.clock-box .settings-btn,
.clock-box .close-btn {
  width: 25px;
  height: 25px;
  min-width: 25px;
  min-height: 25px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  vertical-align: bottom;
}

.clock-box .favorite-btn {
  font-size: 18px;
  transform: translateY(-2px);
}

.clock-box .settings-btn svg {
  width: 15px;
  height: 15px;
  display: block;
}

.clock-box .close-btn svg {
  width: 25px;
  height: 25px;
  display: block;
}

.clock-box .favorite-btn:hover {
  transform: translateY(-3px);
}

.clock-box .favorite-btn,
.clock-box .settings-btn,
.clock-box .close-btn {
  border: 1px solid transparent;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.clock-box .favorite-btn.active {
  background: transparent;
}

.clock-box .favorite-btn:hover,
.clock-box .settings-btn:hover,
.clock-box .close-btn:hover {
  background: transparent;
  border-color: transparent;
}

.clock-box .favorite-btn,
.clock-box .settings-btn,
.clock-box .close-btn {
  color: var(--card-control-color, #ffffff) !important;
}

.clock-box .settings-btn svg,
.clock-box .close-btn svg {
  stroke: var(--card-control-color, #ffffff) !important;
}

.time-tip {
  min-height: 48px;
  margin-top: 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 0 18px;
  border-radius: 14px;
  background: linear-gradient(90deg, #eaf4ff, #f5fbff);
  color: #155db2;
  font-size: 13px;
  font-weight: 700;
}

.time-tip-left {
  display: flex;
  align-items: center;
  gap: 6px;
}

.time-tip-actions {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
}

.time-tip-icon {
  width: auto;
  height: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  font-size: 17px;
}

.time-tip-close {
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
}

.time-bottom-status {
  min-height: 54px;
  margin-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 18px;
  border: 1px solid var(--time-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--time-shadow-soft);
  color: #596781;
  font-size: 13px;
  font-weight: 700;
}

.status-left,
.status-right,
.status-item {
  display: flex;
  align-items: center;
  gap: 12px;
}

.status-left {
  gap: 22px;
}

.divider {
  width: 1px;
  height: 24px;
  background: var(--time-line);
}

.green-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--time-green);
  box-shadow: 0 0 0 4px rgba(23, 178, 106, 0.12);
}

.credit {
  color: #1769d8;
  font-weight: 900;
}

.time-dashboard-aside {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.dashboard-panel {
  padding: 18px;
  border: 1px solid var(--time-line);
  border-radius: 20px;
  background: var(--time-surface);
  box-shadow: var(--time-shadow-soft);
  backdrop-filter: blur(14px);
}

.dashboard-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.dashboard-panel-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #182235;
}

.dashboard-panel-subtitle {
  margin: 5px 0 0 30px;
  color: #667085;
  font-size: 13px;
  font-weight: 600;
}

.map-dashboard-panel {
  padding: 20px;
  border-color: #dce7f3;
  border-radius: 16px;
  background: linear-gradient(145deg, #ffffff 0%, #fbfdff 100%);
  box-shadow: 0 16px 36px rgba(37, 65, 102, 0.09);
}

.map-dashboard-panel .dashboard-panel-head {
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid #e5edf6;
}

.map-title-group {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.map-title-mark {
  width: 5px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--time-blue), var(--time-teal));
  box-shadow: 0 5px 14px rgba(47, 128, 237, 0.2);
}

.map-dashboard-panel .dashboard-panel-title {
  font-size: 17px;
  letter-spacing: -0.02em;
}

.map-dashboard-panel .dashboard-panel-subtitle {
  margin: 4px 0 0;
  font-size: 12px;
  font-weight: 600;
}

.map-city-count {
  display: grid;
  grid-template-columns: auto auto;
  align-items: baseline;
  gap: 6px;
  padding-left: 15px;
  border-left: 1px solid #dce7f3;
  color: #637188;
  white-space: nowrap;
}

.map-city-count strong {
  color: #0f766e;
  font-size: 22px;
  line-height: 1;
  font-weight: 850;
}

.map-city-count span {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.map-box {
  height: 240px;
  margin: 0;
  border: 1px solid #e3edf7;
  border-radius: 12px;
  background: linear-gradient(180deg, #f8fbff, #eff6fd);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 8px 22px rgba(46, 80, 119, 0.06);
  position: relative;
  overflow: hidden;
}

.selected-cities-map {
  width: 100%;
  height: 100%;
  background: #f7fbff;
}

.selected-cities-map.leaflet-container {
  background: #f7fbff;
}

.selected-cities-map .world-country-shape {
  vector-effect: non-scaling-stroke;
}

.selected-cities-map .map-vertical-stretch {
  top: var(--map-vertical-offset, -36px);
  width: 100%;
  height: 100%;
  transform: scaleY(var(--map-vertical-scale, 1.35)) !important;
  transform-origin: 50% 50%;
}

.selected-cities-map .map-vertical-stretch .city-map-marker {
  transform: scaleY(var(--map-marker-counter-scale, 0.74074));
  transform-origin: 50% 50%;
}

.selected-cities-map .leaflet-control-container {
  display: none;
}

.selected-cities-map .leaflet-pane,
.selected-cities-map .leaflet-map-pane,
.selected-cities-map .leaflet-overlay-pane,
.selected-cities-map .leaflet-marker-pane {
  pointer-events: none;
}

.city-map-marker {
  display: block;
  position: relative;
  width: 16px;
  height: 16px;
  box-sizing: border-box;
  border: 3px solid #fff;
  border-radius: 999px;
  background: var(--time-orange);
  box-shadow: 0 5px 12px rgba(16, 24, 40, 0.18);
}

.selected-cities-map .leaflet-marker-icon {
  pointer-events: auto;
  cursor: default;
}

.city-map-marker-label {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 9px);
  z-index: 10;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 6px;
  background: #17243a;
  color: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.22);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.2;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition:
    opacity 0.16s ease,
    transform 0.16s ease,
    visibility 0.16s ease;
}

.city-map-marker-label::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  border: 5px solid transparent;
  border-top-color: #17243a;
  transform: translateX(-50%);
}

.city-map-marker-label-name {
  display: block;
}

.city-map-marker-label-name + .city-map-marker-label-name {
  margin-top: 5px;
  padding-top: 5px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.leaflet-marker-icon:hover .city-map-marker-label,
.leaflet-marker-icon:focus .city-map-marker-label {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.city-map-marker-teal {
  background: var(--time-teal);
}

.city-map-marker-blue {
  background: var(--time-blue);
}

.map-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #667085;
  font-size: 13px;
  font-weight: 700;
}

.meeting-dashboard-panel {
  padding: 20px;
  border-color: #dce7f3;
  border-radius: 16px;
  background: linear-gradient(145deg, #fff 0%, #fbfdff 100%);
  box-shadow: 0 16px 36px rgba(37, 65, 102, 0.09);
}

.meeting-dashboard-panel .dashboard-panel-head {
  align-items: center;
  margin-bottom: 0;
  padding-bottom: 14px;
  border-bottom: 1px solid #e5edf6;
}

.meeting-dashboard-panel .dashboard-panel-subtitle {
  margin: 4px 0 0;
}

.meeting-title-group {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.meeting-title-mark {
  width: 5px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 3px;
  background: linear-gradient(180deg, #7aa7ff, #8edbc7);
}

.meeting-settings-button {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid #dce7f3;
  border-radius: 8px;
  background: #fff;
  color: #52647c;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    color 0.18s ease,
    background 0.18s ease;
}

.meeting-settings-button:hover {
  border-color: #9dbcf2;
  background: #f5f9ff;
  color: #2867c7;
}

.meeting-settings-button svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.meeting-list {
  position: relative;
  display: grid;
  gap: 11px;
  margin-top: 17px;
}

.best-meeting-connector {
  position: absolute;
  z-index: 6;
  width: 0;
  border-left: 1px dotted #8faed1;
  pointer-events: none;
}

.best-meeting-band {
  position: absolute;
  z-index: 3;
  background: rgba(201, 221, 248, 0.48);
  cursor: help;
}

.best-meeting-band-tooltip {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  z-index: 20;
  display: grid;
  gap: 5px;
  min-width: 190px;
  padding: 9px 11px;
  border: 1px solid #dce7f3;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.16);
  color: #12345b;
  font-size: 11px;
  line-height: 1.25;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition:
    opacity 0.15s ease,
    transform 0.15s ease,
    visibility 0.15s ease;
}

.best-meeting-band-tooltip strong {
  font-size: 13px;
  font-weight: 850;
  white-space: nowrap;
}

.best-meeting-band-tooltip span {
  color: #748198;
  font-weight: 650;
  white-space: nowrap;
}

.best-meeting-band:hover .best-meeting-band-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.best-meeting-unavailable {
  position: absolute;
  z-index: 5;
  background: #f6c8cc;
  pointer-events: none;
}

.meeting-empty {
  padding: 18px 0 8px;
  color: #748198;
  font-size: 13px;
  text-align: center;
}

.meeting-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(64px, 1fr) 62px minmax(76px, 112px) 62px;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-size: 12px;
  font-weight: 750;
}

.meeting-city {
  min-width: 0;
  color: #182235;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.meeting-time,
.meeting-end {
  color: #596781;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}

.bar-track {
  position: relative;
  height: 12px;
  overflow: visible;
  border: 1px solid #dfe8f2;
  border-radius: 4px;
  background: #edf2f7;
}

.work-segment {
  position: absolute;
  z-index: 4;
  top: 1px;
  bottom: 1px;
  min-width: 2px;
  border-radius: 0;
  background: #8edbc7;
}

.work-segment:hover,
.work-segment:focus-visible {
  z-index: 10;
}

.work-segment.is-work-start {
  border-radius: 2px 0 0 2px;
}

.work-segment.is-work-end {
  border-radius: 0 2px 2px 0;
}

.work-segment.is-work-start.is-work-end {
  border-radius: 2px;
}

.work-segment.is-best-meeting-time {
  background: #c1c3eb;
}

.work-segment::after {
  content: attr(data-work-hours);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  z-index: 20;
  padding: 6px 8px;
  border-radius: 5px;
  background: #17243a;
  color: #fff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.2);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition:
    opacity 0.15s ease,
    transform 0.15s ease,
    visibility 0.15s ease;
}

.work-segment:hover::after,
.work-segment:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.best-time {
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid #e5edf6;
}

.best-label {
  color: #52647c;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.best-hour {
  display: grid;
  gap: 7px;
  margin-top: 8px;
}

.best-window-item {
  display: grid;
  gap: 2px;
  padding-left: 10px;
  border-left: 3px solid #8edbc7;
}

.best-window-range {
  color: #12345b;
  font-size: 14px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.best-window-excluded,
.best-summary {
  color: #748198;
  font-size: 11px;
  font-weight: 650;
}

.best-summary {
  margin-top: 8px;
}

#bestMeetingZone {
  width: 100%;
  margin-top: 16px;
  text-align: center;
}

.meeting-modal[hidden] {
  display: none;
}

.meeting-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: grid;
  place-items: center;
  padding: 20px;
}

.meeting-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(4px);
}

.meeting-modal-dialog {
  position: relative;
  width: min(680px, 100%);
  max-height: min(680px, calc(100vh - 40px));
  overflow: auto;
  border: 1px solid #dce7f3;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.25);
}

.meeting-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid #e5edf6;
  background: linear-gradient(145deg, #fff, #f7faff);
}

.meeting-modal-head h3 {
  margin: 0;
  color: #182235;
  font-size: 18px;
}

.meeting-modal-head p {
  margin: 4px 0 0;
  color: #748198;
  font-size: 12px;
}

.meeting-modal-close {
  display: inline-grid;
  place-items: center;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  min-width: 32px;
  min-height: 32px;
  padding: 0;
  border: 1px solid #dce7f3;
  border-radius: 7px;
  background: #fff;
  color: #52647c;
  line-height: 0;
  cursor: pointer;
}

.meeting-modal-close svg {
  display: block;
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
}

.meeting-work-list {
  display: grid;
  gap: 9px;
  padding: 16px 20px 20px;
  background: #f7f9fc;
}

.meeting-work-row {
  display: grid;
  grid-template-columns: minmax(130px, 1fr) 156px 22px 156px;
  align-items: end;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid #e1e9f2;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 4px 12px rgba(37, 65, 102, 0.04);
}

.meeting-work-city {
  min-width: 0;
  overflow: hidden;
  color: #25334a;
  font-size: 13px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
  align-self: center;
}

.meeting-time-field {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.meeting-time-field > span {
  color: #758299;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.meeting-time-separator {
  align-self: center;
  padding-top: 16px;
  color: #8b99ad;
  font-size: 16px;
  text-align: center;
}

.meeting-work-row input[type='time'] {
  width: 100%;
  min-width: 0;
  height: 42px;
  padding: 0 10px;
  border: 1px solid #d5e0ec;
  border-radius: 8px;
  background: #fbfdff;
  color: #25334a;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  color-scheme: light;
}

.meeting-work-row input[type='time']:focus {
  outline: 3px solid rgba(47, 128, 237, 0.13);
  border-color: #76a8ef;
}

.meeting-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  padding: 14px 20px 18px;
  border-top: 1px solid #e5edf6;
  background: #fff;
}

.meeting-modal-actions .btn-primary,
.meeting-modal-actions .btn-ghost {
  min-width: 116px;
  border-radius: 8px;
}

.manual-location-form {
  padding: 18px 20px 0;
}

.manual-location-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.manual-location-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.manual-location-field span {
  color: #52647c;
  font-size: 12px;
  font-weight: 800;
}

.manual-location-field input {
  width: 100%;
  height: 42px;
  box-sizing: border-box;
  padding: 0 11px;
  border: 1px solid #d8e3ef;
  border-radius: 8px;
  background: #fff;
  color: #182235;
  font: inherit;
  outline: none;
}

.manual-location-field input:focus {
  border-color: #76a8ef;
  box-shadow: 0 0 0 3px rgba(47, 128, 237, 0.13);
}

.manual-location-help {
  grid-column: 1 / -1;
  margin: -2px 0 0;
  color: #748198;
  font-size: 12px;
  line-height: 1.5;
}

.manual-location-status {
  min-height: 20px;
  margin: 13px 0 0;
  color: #596781;
  font-size: 12px;
  font-weight: 700;
}

.manual-location-status.is-error {
  color: #c43232;
}

.manual-location-status.is-success {
  color: #0f766e;
}

.manual-location-submit[disabled] {
  opacity: 0.62;
  cursor: wait;
}

[data-theme='dark'] .manual-location-field span,
[data-theme='dark'] .manual-location-help,
[data-theme='dark'] .manual-location-status {
  color: var(--time-muted);
}

[data-theme='dark'] .manual-location-field input {
  border-color: var(--time-line-strong);
  background: #111c2d;
  color: var(--time-text);
}

body.meeting-modal-open {
  overflow: hidden;
}

.favorites-head {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--time-line);
}

.favorites-head .manage {
  justify-self: end;
  margin-left: 0;
}

.manage {
  border: 0;
  background: transparent;
  color: #1769d8;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.manage[aria-pressed='true'] {
  color: #b54708;
}

.favorite-list {
  width: 100%;
  display: grid;
  gap: 0;
}

.favorite-row {
  width: 100%;
  min-height: 42px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 24px;
  gap: 10px;
  align-items: center;
  box-sizing: border-box;
  color: #182235;
  font-size: 13px;
  font-weight: 700;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.favorite-row:hover,
.favorite-row:focus-visible {
  color: #1769d8;
  outline: none;
}

.favorite-row span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tz-chip {
  height: 24px;
  display: inline-grid;
  place-items: center;
  justify-self: end;
  padding: 0 8px;
  border-radius: 8px;
  background: #eef2f7;
  color: #667085;
  font-size: 11px;
  font-weight: 900;
}

.favorite-star {
  justify-self: end;
  text-align: center;
  font-size: 20px;
  color: var(--time-orange);
}

.favorite-remove {
  display: none;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 999px;
  color: #b42318;
  background: #fee4e2;
  font-weight: 900;
}

.favorites-managing .favorite-row {
  grid-template-columns: minmax(0, 1fr) auto 24px 22px;
}

.favorites-managing .favorite-remove {
  display: inline-grid;
}

.favorite-empty {
  margin: 0;
  color: #667085;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.6;
}

.time-feedback-toast {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 10020;
  max-width: min(320px, calc(100vw - 48px));
  padding: 4px 4px;
  border-radius: 18px;
  background: rgba(205, 250, 233, 0.92);
  color: #394b7e;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.24);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.96);
  transition:
    opacity 0.18s ease,
    transform 0.18s ease;
}

.time-feedback-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

[data-theme='dark'] .search-box-shell,
[data-theme='dark'] .time-btn,
[data-theme='dark'] .dashboard-panel,
[data-theme='dark'] .time-bottom-status,
[data-theme='dark'] .panel-link,
[data-theme='dark'] .favorite-row,
[data-theme='dark'] .small-chip {
  background: var(--panel-strong);
  color: var(--ink-strong);
}

[data-theme='dark'] .time-hero h1,
[data-theme='dark'] .dashboard-panel-title,
[data-theme='dark'] .meeting-city {
  color: var(--time-text);
}

[data-theme='dark'] .time-hero .subtitle,
[data-theme='dark'] .dashboard-panel-subtitle,
[data-theme='dark'] .meeting-time,
[data-theme='dark'] .meeting-end,
[data-theme='dark'] .meeting-empty,
[data-theme='dark'] .best-label {
  color: var(--time-muted);
}

[data-theme='dark'] .time-toolbar,
[data-theme='dark'] .search-box-shell,
[data-theme='dark'] .time-btn,
[data-theme='dark'] .time-bottom-status,
[data-theme='dark'] .map-dashboard-panel,
[data-theme='dark'] .meeting-dashboard-panel {
  border-color: var(--time-line);
  background: var(--time-surface);
  color: var(--time-text-soft);
  box-shadow: var(--time-shadow-soft);
}

[data-theme='dark'] .search-box-shell input,
[data-theme='dark'] .time-btn {
  color: var(--time-text);
}

[data-theme='dark'] .time-toolbar,
[data-theme='dark'] .map-dashboard-panel,
[data-theme='dark'] .meeting-dashboard-panel {
  background: linear-gradient(145deg, rgba(17, 28, 45, 0.97), rgba(12, 21, 35, 0.96));
}

[data-theme='dark'] .map-dashboard-panel .dashboard-panel-head,
[data-theme='dark'] .meeting-dashboard-panel .dashboard-panel-head,
[data-theme='dark'] .best-time {
  border-color: var(--time-line);
}

[data-theme='dark'] .time-tip {
  border: 1px solid #243852;
  background: linear-gradient(90deg, rgba(30, 64, 105, 0.52), rgba(17, 44, 67, 0.48));
  color: #bfdbfe;
}

[data-theme='dark'] .selected-cities-map,
[data-theme='dark'] .selected-cities-map.leaflet-container {
  background: #0b1524;
}

[data-theme='dark'] .map-box {
  border-color: #2a3b50;
  background: #0b1524;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
}

[data-theme='dark'] .map-city-count {
  border-color: var(--time-line);
  color: var(--time-muted);
}

[data-theme='dark'] .selected-cities-map .world-country-shape {
  fill: #263a54 !important;
  stroke: #60748e !important;
  stroke-opacity: 0.58 !important;
}

[data-theme='dark'] .meeting-settings-button {
  border-color: var(--time-line-strong);
  background: #111c2d;
  color: #b8c7da;
}

[data-theme='dark'] .meeting-settings-button:hover {
  border-color: #4f79ad;
  background: #17263b;
  color: #dbeafe;
}

[data-theme='dark'] .bar-track {
  border-color: #3b4d63;
  background: #dce7f2;
}

[data-theme='dark'] .meeting-modal-dialog,
[data-theme='dark'] .meeting-modal-head,
[data-theme='dark'] .meeting-modal-actions {
  border-color: var(--time-line);
  background: #0f172a;
  color: var(--time-text-soft);
}

[data-theme='dark'] .meeting-modal-head h3,
[data-theme='dark'] .meeting-work-city {
  color: var(--time-text);
}

[data-theme='dark'] .meeting-modal-head p,
[data-theme='dark'] .meeting-time-field span {
  color: var(--time-muted);
}

[data-theme='dark'] .meeting-work-list {
  background: #0b1422;
}

[data-theme='dark'] .meeting-work-row,
[data-theme='dark'] .meeting-work-row input[type='time'],
[data-theme='dark'] .meeting-modal-close {
  border-color: var(--time-line-strong);
  background: #111c2d;
  color: var(--time-text-soft);
}

[data-theme='dark'] #reset-button.reset-group-btn {
  border-color: #33465f !important;
  background: #111c2d !important;
  color: #cbd5e1 !important;
  box-shadow: none !important;
}

[data-theme='dark'] #reset-button.reset-group-btn:hover {
  border-color: #7f4b52 !important;
  background: #251923 !important;
  color: #fda4af !important;
}

body.time-fullscreen-mode .time-dashboard-aside,
body.time-fullscreen-mode .time-hero,
body.time-fullscreen-mode .time-tip,
body.time-fullscreen-mode .time-bottom-status {
  display: none !important;
}

body.time-fullscreen-mode .calculator-page.time-dashboard-page,
body.time-fullscreen-mode .calculator-grid.time-dashboard-shell {
  width: 100%;
  margin: 0;
  display: block;
}

body.time-fullscreen-mode .time-toolbar {
  margin: 0;
  border-radius: 0;
  min-height: 64px;
  height: 64px;
  display: grid;
  grid-template-columns: minmax(140px, 1fr) auto minmax(140px, 1fr);
  align-items: center;
  gap: 14px;
  padding: 0 20px;
  border-left: 0;
  border-right: 0;
  border-top: 0;
  border-bottom: 1px solid #dce5ef;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 4px 18px rgba(37, 65, 102, 0.05);
  backdrop-filter: blur(18px);
}

body.time-fullscreen-mode .time-toolbar .city-search-field,
body.time-fullscreen-mode .time-toolbar .group-tabs {
  display: none !important;
}

body.time-fullscreen-mode .fullscreen-brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  min-width: 0;
  text-decoration: none;
}

body.time-fullscreen-mode .fullscreen-brand img {
  display: block;
  width: auto;
  height: 50px;
  max-width: 160px;
  object-fit: contain;
}

body.time-fullscreen-mode .fullscreen-toolbar-title {
  display: block;
  justify-self: center;
  margin: 0;
  color: #182235;
  font-size: 27px;
  line-height: 1;
  font-weight: 760;
  letter-spacing: -0.03em;
  text-align: center;
  white-space: nowrap;
}

body.time-fullscreen-mode #fullscreen-button {
  justify-self: end;
  width: 88px;
  min-width: 88px;
  height: 36px;
  padding: 0 16px;
  border: 1px solid #d5e1ee;
  border-radius: 8px;
  background: #f5f8fc;
  color: #1769d8;
  box-shadow: none;
}

body.time-fullscreen-mode .time-dashboard-main {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: #f3f6fa;
}

body.time-fullscreen-mode .clock-board-shell,
body.time-fullscreen-mode .widget-grid.city-grid {
  flex: 1 1 auto;
  min-height: 0;
}

body.time-fullscreen-mode .clock-board-shell {
  background: linear-gradient(180deg, #f7f9fc 0%, #f1f5f9 100%);
}

body.time-fullscreen-mode .fullscreen-group-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  box-sizing: border-box;
  flex: 0 0 auto;
  align-items: center;
  align-self: center;
  gap: 0;
  width: min(520px, calc(100vw - 32px));
  height: 42px;
  margin: 10px auto 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-bottom: 1px solid #d7e1ec;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body.time-fullscreen-mode .fullscreen-group-tab {
  width: 100%;
  height: 42px;
  min-width: 0;
  padding: 0 8px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #617086;
  font-size: 12px;
  font-weight: 760;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
  transition:
    color 0.16s ease,
    background 0.16s ease,
    box-shadow 0.16s ease;
}

body.time-fullscreen-mode .fullscreen-group-tab:hover {
  color: #1769d8;
  background: rgba(226, 237, 250, 0.42);
}

body.time-fullscreen-mode .fullscreen-group-tab.active {
  background: transparent;
  color: #0f67d8;
  box-shadow: inset 0 -3px 0 #2f80ed;
}

[data-theme='dark'] body.time-fullscreen-mode .fullscreen-group-tabs {
  border-color: rgba(148, 163, 184, 0.24);
  background: transparent;
  box-shadow: none;
}

[data-theme='dark'] body.time-fullscreen-mode .fullscreen-group-tab {
  color: #aebed3;
}

[data-theme='dark'] body.time-fullscreen-mode .fullscreen-group-tab:hover {
  color: #bfdbfe;
  background: rgba(59, 130, 246, 0.12);
}

[data-theme='dark'] body.time-fullscreen-mode .fullscreen-group-tab.active {
  color: #eaf4ff;
  background: transparent;
  box-shadow: inset 0 -3px 0 #60a5fa;
}

body.time-fullscreen-mode .widget-grid.city-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 300px));
  justify-content: center;
  align-content: start;
  overflow: auto;
  padding: 26px 32px 40px;
  gap: 24px;
}

body.time-fullscreen-mode .widget-grid.city-grid .clock-box,
body.time-fullscreen-mode .widget-grid.city-grid .clock-box.featured {
  grid-column: span 1;
  width: 100%;
  border-radius: 14px;
  box-shadow: 0 10px 26px rgba(32, 61, 97, 0.13);
}

[data-theme='dark'] body.time-fullscreen-mode,
[data-theme='dark'] body.time-fullscreen-mode #tool,
[data-theme='dark'] body.time-fullscreen-mode .time-dashboard-main {
  background: #08111f;
}

[data-theme='dark'] body.time-fullscreen-mode .time-toolbar {
  border-bottom-color: #26364c;
  background: rgba(10, 19, 32, 0.94);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.24);
}

[data-theme='dark'] body.time-fullscreen-mode .fullscreen-toolbar-title {
  color: #f1f5f9;
}

[data-theme='dark'] body.time-fullscreen-mode #fullscreen-button {
  border-color: #33465f;
  background: #111c2d;
  color: #bfdbfe;
}

[data-theme='dark'] body.time-fullscreen-mode .clock-board-shell {
  background: linear-gradient(180deg, #0b1524 0%, #08111f 100%);
}

[data-theme='dark'] body.time-fullscreen-mode .widget-grid.city-grid .clock-box,
[data-theme='dark'] body.time-fullscreen-mode .widget-grid.city-grid .clock-box.featured {
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.time-dashboard-aside .side-box {
  width: 100%;
}

.time-desktop-share-panel {
  display: block;
}

@media (max-width: 1280px) {
  .calculator-grid.time-dashboard-shell {
    grid-template-columns: 1fr;
  }

  .time-dashboard-aside {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .time-toolbar {
    flex-wrap: wrap;
  }
}

@media (max-width: 1024px) {
  .time-desktop-share-panel {
    display: none;
  }

  .calculator-page.time-dashboard-page {
    width: min(100% - 28px, 900px);
    margin-top: 24px;
  }

  .time-hero {
    align-items: flex-start;
  }

  .time-toolbar .city-search-field {
    max-width: none;
    flex-basis: 100%;
  }

  .time-btn {
    flex: 1 1 160px;
  }

  .group-tabs {
    width: 100%;
    overflow-x: auto;
    justify-content: flex-start;
  }

  .widget-grid.city-grid .clock-box.featured,
  .widget-grid.city-grid .clock-box {
    grid-column: span 1;
  }

  .widget-grid.city-grid {
    grid-template-columns: repeat(
      auto-fit,
      minmax(min(var(--city-card-width, 240px), 100%), var(--city-card-width, 240px))
    );
    justify-content: center;
    justify-items: stretch;
    align-content: start;
  }

  .time-dashboard-aside {
    grid-template-columns: 1fr;
  }
}

.wrap > funify-footer {
  display: block !important;
  width: var(--funify-page-width) !important;
  max-width: none !important;
  margin: 28px auto 0 !important;
  box-sizing: border-box;
}

.wrap
  > funify-footer
  :is(footer, .footer, .site-footer, .funify-footer, .footer-inner, .footer-shell, .footer-wrap) {
  width: 100% !important;
  max-width: none !important;
  box-sizing: border-box;
}

.time-tip-text {
  display: inline-flex;
  flex: 0 1 auto;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.time-tip-message {
  display: block;
  position: relative;
  white-space: nowrap;
  transition:
    transform 0.45s ease,
    opacity 0.45s ease;
  will-change: transform, opacity;
}

.time-tip-message-viewport {
  position: relative;
  display: inline-block;
  width: 65ch;
  max-width: calc(100vw - 180px);
  height: 1.5em;
  overflow: hidden;
  vertical-align: middle;
}

.time-tip-message.is-next {
  position: absolute;
  inset: 0 auto auto 0;
  transform: translateY(110%);
  opacity: 0;
}

.time-tip-message.is-leaving {
  transform: translateY(-110%);
  opacity: 0;
}

.time-tip-message.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.time-tip-left {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  white-space: nowrap;
}

.time-tip-text strong {
  white-space: nowrap;
}

.time-tip-icon {
  flex: 0 0 auto;
}

.mobile-screen-top,
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 1024px) {
  body {
    --mobile-bottom-nav-height: 67px;
    background: #f7f9fc;
    padding-bottom: 0;
    overflow-x: hidden;
  }

  body.time-fullscreen-mode {
    padding-bottom: 0;
  }

  body.time-fullscreen-mode .mobile-screen-top,
  body.time-fullscreen-mode .mobile-bottom-nav {
    display: none !important;
  }

  .wrap {
    display: flex;
    flex-direction: column;
    min-height: 100dvh;
    background: #f7f9fc;
  }

  .wrap > funify-footer {
    display: block !important;
    flex: 0 0 auto;
    width: 100% !important;
    max-width: none !important;
    margin: 0 0 calc(var(--mobile-bottom-nav-height) + env(safe-area-inset-bottom, 0px)) !important;
    padding: 0 4px;
    box-sizing: border-box;
    background: #f7f9fc !important;
  }

  .wrap > funify-footer .footer {
    margin-bottom: 0 !important;
    background: #f7f9fc !important;
  }

  .wrap
    > funify-footer
    :is(footer, .footer, .site-footer, .funify-footer, .footer-inner, .footer-shell, .footer-wrap) {
    width: 100% !important;
    max-width: none !important;
    box-sizing: border-box;
  }

  .mobile-screen-top {
    position: sticky;
    top: 0;
    z-index: 70;
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) 40px;
    align-items: center;
    min-height: 52px;
    padding: 0 12px;
    border-bottom: 1px solid #e7edf5;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 8px 18px rgba(16, 24, 40, 0.04);
    backdrop-filter: blur(16px);
  }

  .mobile-screen-top::after {
    content: '';
    width: 34px;
    height: 34px;
  }

  .mobile-screen-top button {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #1d2939;
    line-height: 1;
    cursor: pointer;
  }

  .mobile-back-button::before {
    content: '';
    width: 10px;
    height: 10px;
    margin-left: 4px;
    border-left: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    border-radius: 1px;
    transform: rotate(45deg);
  }

  .mobile-screen-top button:active {
    background: #eef4ff;
  }

  .mobile-screen-title {
    overflow: hidden;
    color: #101828;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    font-size: 15px;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.25;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.mobile-section-dashboard .mobile-screen-title {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    line-height: 24px;
  }

  body.mobile-section-dashboard .mobile-screen-title::before {
    content: '\1F30D';
    display: block;
    flex: 0 0 auto;
    margin-right: 7px;
    font-size: 18px;
    font-weight: 400;
    line-height: 24px;
    transform: translateY(-2px);
  }

  body.mobile-section-dashboard .mobile-back-button {
    visibility: hidden;
  }

  .calculator-page.time-dashboard-page {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin: 0;
    padding: 14px 12px 16px;
    box-sizing: border-box;
    flex: 1 0 auto;
    min-height: 0;
    overflow-anchor: none;
  }

  .calculator-grid.time-dashboard-shell {
    display: block;
  }

  .calculator-main,
  .time-dashboard-main,
  .time-dashboard-aside {
    width: 100%;
    min-width: 0;
  }

  .map-dashboard-panel,
  .time-bottom-status {
    display: none !important;
  }

  .time-weather-tool {
    gap: 8px;
  }

  .time-toolbar {
    order: 1;
    position: relative;
    z-index: 60;
    display: grid;
    grid-template-columns: 1fr;
    min-height: auto;
    gap: 10px;
    margin: 0 -2px 4px;
    padding: 10px;
    border: 1px solid #e3ebf5;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 10px 24px rgba(37, 65, 102, 0.08);
    backdrop-filter: blur(16px);
  }

  .time-toolbar .city-search-field {
    grid-column: 1 / 2;
    flex: none;
    width: 100%;
    max-width: none;
    min-width: 0;
    height: 44px;
  }

  .search-box-shell {
    height: 44px;
    gap: 9px;
    padding: 0 13px;
    border-color: #e1e9f2;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 8px 18px rgba(16, 24, 40, 0.045);
  }

  .search-box-shell input[type='text'] {
    height: 42px;
    font-size: 14px;
  }

  .city-suggestion-list {
    position: fixed;
    left: 12px;
    right: 12px;
    top: 118px;
    z-index: 10001;
    width: auto;
    min-width: 0;
    max-height: min(58vh, 430px);
  }

  .group-tabs {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    height: 42px;
    gap: 0;
    padding: 0;
    border: 0;
    border-bottom: 1px solid #d7e1ec;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }

  .group-tabs::-webkit-scrollbar {
    display: none;
  }

  .group-tab {
    flex: 0 0 92px;
    width: 92px;
    min-width: 92px;
    height: 42px;
    padding: 0 10px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: #617086;
    font-size: 12px;
    font-weight: 760;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition:
      color 0.16s ease,
      background 0.16s ease,
      box-shadow 0.16s ease;
  }

  .group-tab.active {
    background: transparent;
    color: #0f67d8;
    box-shadow: inset 0 -3px 0 #2f80ed;
  }

  [data-theme='dark'] .group-tabs {
    border-color: rgba(148, 163, 184, 0.24);
  }

  [data-theme='dark'] .group-tab {
    color: #aebed3;
  }

  [data-theme='dark'] .group-tab.active {
    color: #eaf4ff;
    background: transparent;
    box-shadow: inset 0 -3px 0 #60a5fa;
  }

  #fullscreen-button {
    display: none !important;
  }

  .widget-grid.city-grid {
    order: 3;
    grid-template-columns: repeat(
      auto-fit,
      minmax(min(var(--city-card-width, 240px), 100%), var(--city-card-width, 240px))
    );
    justify-content: center;
    justify-items: stretch;
    align-content: start;
    min-height: 180px;
    gap: 16px;
    padding: 0;
  }

  .widget-grid.city-grid .clock-box,
  .widget-grid.city-grid .clock-box.featured {
    grid-column: span 1;
    width: 100%;
    min-height: 206px;
    aspect-ratio: auto;
    border-radius: 18px;
    box-shadow: 0 12px 28px rgba(32, 61, 97, 0.14);
  }

  .widget-grid.city-grid .clock-box:has(.settings-panel.active),
  .clock-box:has(.settings-panel.active) {
    z-index: 10020;
  }

  .clock-box .settings-panel,
  .clock-box.settings-panel-open-left .settings-panel,
  .clock-box.settings-panel-open-below .settings-panel {
    position: fixed;
    z-index: 10021;
    left: 12px;
    right: 12px;
    top: auto;
    bottom: calc(84px + env(safe-area-inset-bottom, 0px));
    width: auto;
    max-height: min(70vh, 520px);
    border-radius: 18px;
    transform: none;
  }

  .clock-board-shell {
    order: 3;
  }

  .time-bottom-status {
    order: 4;
  }

  .time-tip {
    order: 2;
    margin: 0 0 4px;
    min-height: 42px;
    padding: 0 14px;
    border-radius: 16px;
    background: #eef6ff;
    color: #1769d8;
    font-size: 12px;
    overflow: hidden;
  }

  .time-tip-actions {
    display: none;
  }

  .time-tip-left {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    overflow: hidden;
  }

  .time-tip-text {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    gap: 8px;
    white-space: nowrap;
    overflow: hidden;
  }

  .time-tip-text strong {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .time-tip-message {
    display: inline-block;
    width: max-content;
    white-space: nowrap;
  }

  .time-tip-message-viewport {
    flex: 1 1 auto;
    min-width: 0;
    max-width: none;
    height: 1.5em;
    overflow: hidden;
  }

  .time-tip-message-viewport.mobile-tip-overflow
    .time-tip-message:not(.is-next):not(.is-leaving):not(.is-visible) {
    animation: mobileTipFlow var(--mobile-tip-flow-duration, 7s) ease-in-out forwards;
  }

  .time-tip-message.is-next,
  .time-tip-message.is-leaving,
  .time-tip-message.is-visible {
    animation: none;
  }

  @keyframes mobileTipFlow {
    0%,
    20% {
      transform: translateX(0);
    }

    100% {
      transform: translateX(var(--mobile-tip-flow-distance, -40px));
    }
  }

  .time-dashboard-aside {
    order: 5;
    display: block;
    margin-top: 14px;
  }

  .dashboard-panel {
    padding: 16px;
    border-color: #e3ebf5;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(37, 65, 102, 0.07);
  }

  .dashboard-panel + .dashboard-panel {
    margin-top: 12px;
  }

  .dashboard-panel-head {
    align-items: center;
    margin-bottom: 12px;
  }

  .dashboard-panel-title {
    gap: 8px;
    font-size: 15px;
  }

  .dashboard-panel-subtitle {
    margin-left: 0;
    font-size: 12px;
  }

  .meeting-dashboard-panel .dashboard-panel-head {
    padding-bottom: 12px;
    border-bottom: 1px solid #edf2f7;
  }

  .meeting-row {
    grid-template-columns: minmax(76px, 1fr) 60px minmax(80px, 1.15fr) 54px;
    gap: 6px;
    padding: 8px 0;
  }

  .best-time {
    margin-top: 12px;
    padding: 12px;
    border-radius: 16px;
    background: #ecfdf3;
  }

  .favorite-row {
    min-height: 58px;
    grid-template-columns: minmax(0, 1fr) auto 26px;
    padding: 8px 0;
    border-bottom: 1px solid #eef2f7;
  }

  .favorite-row:last-child {
    border-bottom: 0;
  }

  .tz-chip {
    max-width: 118px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .meeting-modal-dialog {
    width: min(100% - 24px, 520px);
    max-height: min(86vh, 720px);
    border-radius: 18px;
  }

  .meeting-work-row {
    grid-template-columns: 1fr 1fr;
    align-items: start;
    padding: 12px;
    gap: 9px;
  }

  .meeting-work-city {
    grid-column: 1 / -1;
  }

  .meeting-time-separator {
    display: none;
  }

  .manual-location-fields {
    grid-template-columns: 1fr;
  }

  .mobile-bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 80;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    height: calc(64px + env(safe-area-inset-bottom, 0px));
    box-sizing: border-box;
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid #e3ebf5;
    border-radius: 18px 18px 0 0;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 -12px 28px rgba(16, 24, 40, 0.08);
    backdrop-filter: blur(18px);
    overflow: hidden;
  }

  .mobile-bottom-nav button {
    display: grid;
    grid-template-rows: 24px 14px;
    justify-items: center;
    align-content: center;
    gap: 3px;
    width: 100%;
    height: 100%;
    min-height: 0;
    padding: 0;
    border: 0;
    border-radius: 16px;
    background: transparent;
    color: #667085;
    font: inherit;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
  }

  .mobile-bottom-nav button > span:last-child {
    line-height: 14px;
  }

  .mobile-bottom-nav .mobile-nav-icon {
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: inherit;
    font-size: 17px;
    line-height: 1;
  }

  .mobile-bottom-nav .mobile-nav-icon svg {
    width: 24px;
    height: 24px;
    display: block;
  }

  .mobile-bottom-nav button.active {
    color: #0f67d8;
  }

  .mobile-bottom-nav button.active .mobile-nav-icon {
    background: #0f67d8;
    color: #fff;
    box-shadow: 0 8px 16px rgba(15, 103, 216, 0.2);
  }

  body.mobile-section-dashboard .map-dashboard-panel,
  body.mobile-section-dashboard
    .time-dashboard-aside
    .dashboard-panel[data-mobile-section-panel='favorites'] {
    display: none !important;
  }

  #bestMeetingZone {
    display: none !important;
  }

  body.mobile-section-meeting .map-dashboard-panel,
  body.mobile-section-meeting
    .time-dashboard-aside
    .dashboard-panel[data-mobile-section-panel='favorites'] {
    display: none !important;
  }

  body.mobile-section-meeting #tool,
  body.mobile-section-favorites #tool {
    display: block !important;
    margin-bottom: 14px;
  }

  body.mobile-section-meeting #tool .clock-board-shell,
  body.mobile-section-meeting #tool .time-tip,
  body.mobile-section-meeting #tool .time-bottom-status,
  body.mobile-section-favorites #tool .clock-board-shell,
  body.mobile-section-favorites #tool .time-tip,
  body.mobile-section-favorites #tool .time-bottom-status {
    display: none !important;
  }

  body.mobile-section-meeting #tool .tool-form,
  body.mobile-section-favorites #tool .tool-form {
    gap: 0;
  }

  body.mobile-section-meeting #tool .time-toolbar,
  body.mobile-section-favorites #tool .time-toolbar {
    margin: 0 -2px 14px;
  }

  body.mobile-section-meeting .time-dashboard-aside,
  body.mobile-section-meeting .meeting-dashboard-panel {
    margin-top: 0;
  }

  body.mobile-section-favorites .map-dashboard-panel,
  body.mobile-section-favorites .meeting-dashboard-panel {
    display: none !important;
  }

  [data-theme='dark'] body,
  [data-theme='dark'] .wrap {
    background: #08111f;
  }

  [data-theme='dark'] .wrap > funify-footer,
  [data-theme='dark'] .wrap > funify-footer .footer {
    background: #08111f !important;
  }

  [data-theme='dark'] .mobile-screen-top,
  [data-theme='dark'] .mobile-bottom-nav,
  [data-theme='dark'] .time-toolbar,
  [data-theme='dark'] .dashboard-panel {
    border-color: #26364c;
    background: rgba(15, 23, 42, 0.96);
    color: #e5eefc;
  }

  [data-theme='dark'] .mobile-screen-title,
  [data-theme='dark'] .mobile-screen-top button {
    color: #f8fafc;
  }

  [data-theme='dark'] .best-time {
    border-color: #2b435e;
    background: linear-gradient(145deg, rgba(13, 31, 50, 0.98), rgba(9, 22, 38, 0.98));
    box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.08);
  }

  [data-theme='dark'] .best-label {
    color: #8fb3d9;
  }

  [data-theme='dark'] .best-window-item {
    border-left-color: #38d6bb;
  }

  [data-theme='dark'] .best-window-range {
    color: #d9ecff;
  }

  [data-theme='dark'] .best-window-excluded,
  [data-theme='dark'] .best-summary {
    color: #9fb0c6;
  }
}

.world-favorite-heart {
  color: #ff4d6d;
}

/* Accessibility and positioning for the shared header integration. */
.time-dashboard-page .sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 1024px) {
  body.mobile-section-dashboard .mobile-screen-top {
    display: none;
  }

  body.mobile-section-dashboard .calculator-page.time-dashboard-page {
    padding-top: 24px;
  }

  body.mobile-section-meeting .time-hero,
  body.mobile-section-favorites .time-hero,
  body.mobile-section-map .time-hero {
    display: none;
  }

  .time-hero {
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
    margin: 0 4px 20px;
  }

  .time-hero h1 {
    font-size: clamp(26px, 5vw, 32px);
    line-height: 1.15;
  }

  .time-hero .subtitle {
    margin-top: 8px;
    font-size: 13px;
  }

  .time-hero-actions {
    justify-content: space-between;
    gap: 12px;
  }

  .time-hero-description-desktop {
    display: none;
  }

  .time-hero-description-mobile {
    display: inline;
  }

  .time-dashboard-page .city-suggestion-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
  }
}
