@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Playfair+Display:wght@500;600&display=swap');

:root {
  --background: #0d1523;
  --surface: #141f31;
  --surface-raised: #1a273b;
  --border: rgba(185, 204, 231, 0.12);
  --text: #f1f5fb;
  --muted: #94a7c1;
  --faint: #687c98;
  --blue: #69a6ff;
  --orange: #f6a15d;
  --purple: #ba8bff;
  --green: #6ed1aa;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  background: var(--background);
  font-family: 'DM Sans', sans-serif;
  -webkit-font-smoothing: antialiased;
}

button { font: inherit; }

.dashboard-shell {
  width: min(1480px, calc(100% - 64px));
  margin: 0 auto;
  padding: 42px 0 26px;
}

.topbar, .card-heading, .calendar-header, .scripture-footer, .dashboard-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar { margin-bottom: 36px; }

.brand-lockup, .topbar-meta, .calendar-title, .scripture-label { display: flex; align-items: center; }

.brand-mark {
  display: grid;
  grid-template-columns: repeat(2, 9px);
  gap: 4px;
  width: 34px;
  height: 34px;
  margin-right: 14px;
  padding: 6px;
  border: 1px solid rgba(105, 166, 255, .42);
  border-radius: 10px;
  background: rgba(105, 166, 255, .1);
  transform: rotate(2deg);
}

.brand-mark span { border-radius: 2px; background: var(--blue); }
.brand-mark span:nth-child(2) { opacity: .55; }
.brand-mark span:nth-child(3) { opacity: .75; }

.eyebrow, .section-label {
  margin: 0 0 5px;
  color: var(--blue);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .17em;
}

h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 0; font-size: clamp(20px, 2vw, 27px); letter-spacing: -.03em; }
h2 { margin-bottom: 0; font-size: 16px; font-weight: 600; letter-spacing: -.02em; }

.topbar-meta { gap: 19px; }
.date-block { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.25; }
.date-day { color: var(--text); font-size: 13px; font-weight: 600; }
.date-full { color: var(--muted); font-size: 12px; }
.topbar-divider { width: 1px; height: 30px; background: var(--border); }
.clock { color: var(--text); font-size: 24px; font-weight: 500; letter-spacing: -.04em; }
.icon-button, .more-button {
  display: grid;
  place-items: center;
  border: 0;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}
.icon-button { width: 32px; height: 32px; border-radius: 8px; }
.icon-button:hover, .more-button:hover { color: var(--text); background: rgba(255, 255, 255, .06); }
.icon-button svg { width: 18px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.5; }
.more-button { width: 30px; height: 26px; font-size: 15px; letter-spacing: 2px; }

.content-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 17px;
}

.card {
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 18px 45px rgba(0, 0, 0, .13);
}

.weather-card { grid-column: span 4; min-height: 298px; }
.agenda-card { grid-column: span 8; min-height: 298px; }
.calendar-card { grid-column: span 3; min-height: 235px; padding: 21px; }
.scripture-card {
  grid-column: span 6;
  min-height: 235px;
  border-color: rgba(241, 212, 145, .17);
  background: linear-gradient(135deg, #202333, #191d2d 63%, #252638);
}

.card-heading { align-items: flex-start; margin-bottom: 23px; }
.card-heading h2 { font-size: 18px; }
.event-count { color: var(--faint); font-size: 11px; }

.weather-current { display: flex; align-items: center; margin: 22px 0 15px; }
.temperature { margin-left: 20px; font-size: 58px; font-weight: 500; line-height: .9; letter-spacing: -.08em; }
.temperature span { color: var(--muted); font-size: 30px; vertical-align: top; }
.weather-summary { display: flex; flex-direction: column; gap: 5px; margin-left: 16px; color: var(--muted); font-size: 12px; }
.weather-summary strong { color: var(--text); font-size: 13px; font-weight: 500; }
.weather-details { display: flex; gap: 17px; padding-bottom: 19px; color: var(--muted); font-size: 11px; }
.weather-details b { color: var(--text); font-weight: 600; }
.forecast { display: flex; justify-content: space-between; padding-top: 17px; border-top: 1px solid var(--border); }
.forecast div { display: flex; flex-direction: column; align-items: center; gap: 8px; color: var(--faint); font-size: 10px; }
.forecast b { color: var(--muted); font-size: 11px; font-weight: 500; }
.mini-weather { color: #f8c96d; font-size: 18px; line-height: 1; }
.mini-weather.partly { color: #a3b8d3; }
.mini-weather.rain { color: #77baff; font-size: 22px; }

.sun-icon { position: relative; width: 56px; height: 56px; }
.sun-core { position: absolute; inset: 13px; border-radius: 50%; background: #f7c66e; box-shadow: 0 0 22px rgba(247, 198, 110, .28); }
.ray { position: absolute; left: 26px; top: 0; width: 4px; height: 10px; border-radius: 3px; background: #f7c66e; transform-origin: 2px 28px; }
.ray-1 { transform: rotate(0); }
.ray-2 { transform: rotate(90deg); }
.ray-3 { transform: rotate(180deg); }
.ray-4 { transform: rotate(270deg); }

.agenda-list { position: relative; }
.agenda-row { display: grid; grid-template-columns: 51px 15px 1fr 8px; align-items: center; min-height: 48px; }
.agenda-time { display: flex; align-items: baseline; gap: 3px; color: var(--muted); }
.agenda-time strong { color: var(--text); font-size: 13px; font-weight: 500; }
.agenda-time span { color: var(--faint); font-size: 9px; }
.agenda-line { position: relative; height: 100%; }
.agenda-line::before { position: absolute; top: 0; bottom: 0; left: 5px; width: 1px; background: rgba(151, 174, 205, .2); content: ''; }
.agenda-row:first-child .agenda-line::before { top: 50%; }
.agenda-row:last-child .agenda-line::before { bottom: 50%; }
.agenda-line span { position: absolute; z-index: 1; top: 50%; left: 1px; width: 9px; height: 9px; border: 2px solid var(--surface); border-radius: 50%; background: var(--blue); transform: translateY(-50%); box-shadow: 0 0 0 1px var(--blue); }
.agenda-event { display: flex; flex-direction: column; gap: 3px; padding-left: 9px; }
.agenda-event strong { font-size: 12px; font-weight: 500; }
.agenda-event span { color: var(--faint); font-size: 10px; }
.calendar-dot { display: inline-block; flex: 0 0 auto; width: 8px; height: 8px; border-radius: 50%; }
.calendar-dot.blue, .agenda-line span { background: var(--blue); }
.calendar-dot.orange { background: var(--orange); }
.calendar-dot.purple { background: var(--purple); }
.calendar-dot.green { background: var(--green); }
.current-event .agenda-event strong { color: #acd0ff; }

.calendar-header { margin-bottom: 6px; }
.calendar-title { gap: 9px; }
.calendar-title h2 { font-size: 16px; }
.calendar-owner { margin: 0 0 19px; color: var(--faint); font-size: 10px; }
.calendar-event { display: flex; flex-direction: column; gap: 4px; padding: 12px 0; border-top: 1px solid var(--border); }
.calendar-event strong { font-size: 12px; font-weight: 500; }
.calendar-event > span:not(.event-time) { color: var(--faint); font-size: 10px; }
.event-time { color: var(--muted); font-size: 10px; }
.empty-note { margin-top: 6px; padding-top: 14px; border-top: 1px solid var(--border); color: var(--faint); font-size: 10px; }

.scripture-card { display: flex; flex-direction: column; justify-content: space-between; }
.scripture-label { gap: 9px; }
.scripture-label .section-label { margin: 0; color: #e8bf70; }
.cross-mark { color: #e8bf70; font-size: 17px; transform: rotate(45deg); }
blockquote { max-width: 700px; margin: 14px 0 12px; color: #f6f0df; font-family: 'Playfair Display', Georgia, serif; font-size: clamp(19px, 2.2vw, 26px); line-height: 1.35; letter-spacing: -.02em; }
cite { color: #c9ad75; font-size: 11px; font-style: normal; }
cite span { padding: 0 5px; color: #766b54; }
.scripture-footer { margin-top: 22px; padding-top: 15px; border-top: 1px solid rgba(232, 191, 112, .14); color: #8e8878; font-size: 10px; }
.share-button { border: 0; color: #c9ad75; background: none; font-size: 11px; cursor: pointer; }
.share-button:hover { color: #f6f0df; }
.share-button span { margin-left: 3px; }

.dashboard-footer { margin-top: 18px; color: var(--faint); font-size: 10px; }
.status-dot { display: inline-block; width: 6px; height: 6px; margin-right: 5px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(110, 209, 170, .1); }
.footer-note { opacity: .7; }

@media (max-width: 1050px) {
  .weather-card { grid-column: span 5; }
  .agenda-card { grid-column: span 7; }
  .calendar-card { grid-column: span 6; }
  .scripture-card { grid-column: span 6; }
}

@media (max-width: 720px) {
  .dashboard-shell { width: min(100% - 32px, 540px); padding-top: 26px; }
  .topbar { align-items: flex-start; margin-bottom: 26px; }
  .topbar-meta { gap: 10px; }
  .date-block, .topbar-divider { display: none; }
  .clock { font-size: 20px; }
  .weather-card, .agenda-card, .calendar-card, .scripture-card { grid-column: 1 / -1; }
  .weather-card, .agenda-card { min-height: 0; }
  .calendar-card { min-height: 0; }
  .content-grid { gap: 13px; }
  .card { padding: 20px; border-radius: 15px; }
  .footer-note { display: none; }
}
