:root {
  color-scheme: light;
  --page: #f4f6f8;
  --panel: rgba(255, 255, 255, 0.92);
  --ink: #17202a;
  --muted: #667085;
  --line: #d9dee7;
  --action: #155eef;
  --preview-bg: #202020;
  --preview-fore: #f7f7f7;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--page);
  background-image:
    linear-gradient(rgba(244, 246, 248, 0.35), rgba(244, 246, 248, 0.35)),
    url("./7.jpg?v=20260707-7");
  background-position: center bottom;
  background-repeat: no-repeat;
  background-size: cover;
  color: var(--ink);
  font-family: Arial, "Noto Sans Hebrew", sans-serif;
}

.app-shell {
  width: min(980px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0;
}

.tool {
  display: grid;
  gap: 18px;
}

.topbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

h1 {
  margin: 0;
  font-size: 30px;
  line-height: 1.15;
}

.status-text {
  color: var(--muted);
  font-size: 14px;
}

.topbar-actions {
  display: grid;
  justify-items: end;
  gap: 8px;
}

.secondary-button {
  width: auto;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
}

.controls {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  align-items: end;
  padding: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

label span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.date-field {
  grid-column: span 2;
}

.date-input-row {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(180px, auto);
  gap: 8px;
  align-items: end;
}

.date-input-row input {
  min-width: 0;
}

.now-button {
  min-height: 42px;
  line-height: 1.2;
  white-space: normal;
}

.location-field {
  display: grid;
  grid-column: 1 / -1;
  gap: 10px;
  min-width: 0;
}

.location-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.location-header span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.location-status {
  color: var(--muted);
  font-size: 13px;
  text-align: end;
}

.location-status.error {
  color: #b42318;
}

.location-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.map-view {
  min-height: 240px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
}

input,
select,
button {
  width: 100%;
  min-height: 42px;
  border-radius: 6px;
  font: inherit;
}

input,
select {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--ink);
  padding: 0 10px;
}

button {
  border: 0;
  background: var(--action);
  color: #ffffff;
  font-weight: 700;
  cursor: pointer;
}

.preview {
  min-height: 260px;
  display: grid;
  place-items: center;
  background: var(--preview-bg);
  color: var(--preview-fore);
  border-radius: 8px;
  border: 1px solid var(--line);
}

.sample-text {
  display: grid;
  gap: 10px;
  text-align: center;
}

.sample-text span {
  font-size: 13px;
  font-weight: 700;
}

.sample-text strong {
  font-size: clamp(36px, 10vw, 92px);
  line-height: 1;
}

.results {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.color-card {
  display: grid;
  gap: 8px;
  min-height: 112px;
  padding: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.color-card span,
.color-card small {
  color: var(--muted);
}

.color-card strong {
  overflow-wrap: anywhere;
  font-size: 22px;
}

.next-change-card {
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  min-height: 86px;
}

.next-change-card strong {
  font-size: 28px;
  text-align: end;
}

.next-change-card small {
  grid-column: 1 / -1;
  text-align: end;
}

.next-change-hint {
  color: var(--ink);
  font-weight: 700;
  line-height: 1.45;
}

@media (max-width: 760px) {
  .app-shell {
    width: min(100% - 20px, 980px);
    padding: 16px 0;
  }

  .controls,
  .results {
    grid-template-columns: 1fr;
  }

  .date-field {
    grid-column: auto;
  }

  .date-input-row {
    grid-template-columns: 1fr;
  }

  .location-header,
  .location-search-row {
    display: grid;
    grid-template-columns: 1fr;
  }

  .location-status {
    text-align: start;
  }

  .topbar-actions {
    justify-items: end;
  }

  .next-change-card {
    grid-template-columns: 1fr;
  }

  .next-change-card strong,
  .next-change-card small {
    text-align: start;
  }
}
