/* ===== CSS Variables & Theme ===== */
:root {
  --primary: #1565C0;
  --primary-dark: #0D47A1;
  --primary-light: #42A5F5;
  --secondary: #26A69A;
  --secondary-light: #4DB6AC;

  /* Tide alert colors */
  --tide-exceptional-low: #25A7E3;
  --tide-below-normal: #C6C6C6;
  --tide-normal: #58C596;
  --tide-sustained: #FCDC00;
  --tide-very-sustained: #F6A224;
  --tide-exceptional: #ED393C;

  /* Surfaces */
  --bg: #F5F7FA;
  --surface: #FFFFFF;
  --surface-hover: #F0F4F8;
  --surface-border: rgba(0,0,0,0.06);
  --text: #1A1A2E;
  --text-secondary: #6B7280;
  --text-tertiary: #9CA3AF;

  /* Misc */
  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --shadow: 0 1px 3px rgba(0,0,0,0.06), 0 4px 12px rgba(0,0,0,0.04);
  --shadow-lg: 0 4px 16px rgba(0,0,0,0.08), 0 8px 32px rgba(0,0,0,0.06);
  --shadow-xl: 0 8px 32px rgba(0,0,0,0.12), 0 16px 48px rgba(0,0,0,0.08);
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --header-height: 64px;
  --nav-height: 64px;
}

[data-theme="dark"] {
  --bg: #0F1117;
  --surface: #1A1D2E;
  --surface-hover: #252840;
  --surface-border: rgba(255,255,255,0.06);
  --text: #E8E8F0;
  --text-secondary: #9CA3AF;
  --text-tertiary: #6B7280;
  --shadow: 0 1px 3px rgba(0,0,0,0.3), 0 4px 12px rgba(0,0,0,0.2);
  --shadow-lg: 0 4px 16px rgba(0,0,0,0.4), 0 8px 32px rgba(0,0,0,0.3);
  --shadow-xl: 0 8px 32px rgba(0,0,0,0.5), 0 16px 48px rgba(0,0,0,0.4);
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

.hidden { display: none !important; }

/* ===== Splash Screen ===== */
.splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0D47A1 0%, #1565C0 40%, #26A69A 100%);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.splash.fade-out {
  opacity: 0;
  transform: scale(1.05);
  pointer-events: none;
}

.splash-content {
  text-align: center;
  color: white;
}

.splash-icon {
  margin-bottom: 24px;
}

.splash-logo {
  width: 120px;
  height: 120px;
  border-radius: 28px;
  object-fit: contain;
  animation: waveFloat 2s ease-in-out infinite;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.wave-icon {
  font-size: 72px !important;
  animation: waveFloat 2s ease-in-out infinite;
}

.splash-title {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.splash-subtitle {
  font-size: 1.1rem;
  opacity: 0.85;
  font-weight: 300;
  margin-bottom: 40px;
}

.splash-loader {
  width: 240px;
  height: 4px;
  background: rgba(255,255,255,0.2);
  border-radius: 4px;
  margin: 0 auto 16px;
  overflow: hidden;
}

.splash-progress {
  height: 100%;
  width: 0%;
  background: white;
  border-radius: 4px;
  transition: width 0.3s ease;
}

.splash-status {
  font-size: 0.85rem;
  opacity: 0.7;
}

/* ===== App Header ===== */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--surface);
  border-bottom: 1px solid var(--surface-border);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  height: var(--header-height);
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  height: 100%;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-logo {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  object-fit: contain;
}

.header-icon {
  color: var(--primary);
  font-size: 28px !important;
}

.header-title {
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-meta {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-right: 8px;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.icon-btn:hover {
  background: var(--surface-hover);
  color: var(--primary);
}

.icon-btn .material-icons-round { font-size: 22px; }

/* Header Store Badges */
.header-store-badges {
  display: flex;
  gap: 6px;
}

.header-store-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  background: var(--primary);
  color: #fff;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 600;
  transition: var(--transition);
  white-space: nowrap;
}

.header-store-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(21,101,192,0.3);
}

.header-store-btn svg {
  flex-shrink: 0;
}

.lang-select {
  padding: 6px 8px;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
}

/* ===== Offline Banner ===== */
.offline-banner {
  background: #FFF3E0;
  color: #E65100;
  padding: 8px 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 500;
}

[data-theme="dark"] .offline-banner {
  background: #3E2723;
  color: #FFB74D;
}

/* ===== MOSE Banner ===== */
.mose-banner {
  background: linear-gradient(90deg, #E3F2FD, #E8F5E9);
  color: #1565C0;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 500;
}

[data-theme="dark"] .mose-banner {
  background: linear-gradient(90deg, #0D47A1, #1B5E20);
  color: #90CAF9;
}

/* ===== Tab Navigation ===== */
.tab-nav {
  position: sticky;
  top: var(--header-height);
  z-index: 90;
  display: flex;
  background: var(--surface);
  border-bottom: 1px solid var(--surface-border);
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 12px;
}

.tab-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 10px 8px;
  border: none;
  background: transparent;
  color: var(--text-tertiary);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  font-family: 'Inter', sans-serif;
}

.tab-btn::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 3px;
  background: var(--primary);
  border-radius: 3px 3px 0 0;
  transition: width 0.3s ease;
}

.tab-btn.active {
  color: var(--primary);
}

.tab-btn.active::after {
  width: 48px;
}

.tab-btn .material-icons-round { font-size: 22px; }
.tab-label { font-size: 0.7rem; font-weight: 600; }

/* ===== Tab Content ===== */
.tab-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  padding-bottom: 40px;
  min-height: calc(100vh - var(--header-height) - var(--nav-height));
}

.tab-panel {
  display: none;
  animation: fadeSlideUp 0.4s ease;
}

.tab-panel.active {
  display: block;
}

/* ===== Section Blocks ===== */
.section-block {
  margin-bottom: 24px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-header h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}

.section-header h2 .material-icons-round {
  color: var(--primary);
  font-size: 22px;
}

/* ===== Station Carousel ===== */
.station-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.station-counter {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  min-width: 40px;
  text-align: center;
}

.carousel-btn {
  width: 32px;
  height: 32px;
  border: none;
  background: var(--surface);
  color: var(--text-secondary);
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  box-shadow: var(--shadow);
}

.carousel-btn:hover {
  background: var(--primary);
  color: white;
}

.carousel-container {
  overflow: hidden;
  border-radius: var(--radius);
}

.carousel {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  gap: 16px;
}

.station-card {
  flex: 0 0 100%;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
  cursor: default;
}

.station-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--card-accent, var(--primary));
}

.station-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.station-value {
  font-size: 4rem;
  font-weight: 900;
  text-align: center;
  line-height: 1;
  margin-bottom: 4px;
  font-family: 'JetBrains Mono', monospace;
  transition: color 0.3s ease;
}

.station-unit {
  font-size: 1.5rem;
  font-weight: 400;
  opacity: 0.6;
}

.station-alert {
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 12px;
  padding: 4px 16px;
  border-radius: 20px;
  display: inline-block;
  margin-left: auto;
  margin-right: auto;
  width: fit-content;
}

.station-card .station-alert {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.station-time {
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-tertiary);
  margin-bottom: 16px;
}

.station-next {
  background: var(--surface-hover);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
}

.station-next .material-icons-round {
  font-size: 20px;
  color: var(--primary);
}

.station-next-label {
  color: var(--text-secondary);
  font-weight: 500;
}

.station-next-value {
  font-weight: 700;
  margin-left: auto;
  font-family: 'JetBrains Mono', monospace;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 16px;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-tertiary);
  opacity: 0.3;
  transition: var(--transition);
  cursor: pointer;
  border: none;
}

.carousel-dot.active {
  opacity: 1;
  background: var(--primary);
  width: 24px;
  border-radius: 4px;
}

/* ===== Charts ===== */
.chart-container {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  position: relative;
  height: 300px;
}

.chart-container canvas {
  width: 100% !important;
  height: 100% !important;
}

/* ===== Forecast Cards ===== */
.forecast-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.forecast-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  cursor: default;
  position: relative;
  overflow: hidden;
}

.forecast-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.forecast-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--card-accent, var(--primary));
}

.forecast-date {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
  text-transform: capitalize;
}

.forecast-day {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-bottom: 12px;
}

.forecast-extremes {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.extreme-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
}

.extreme-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.extreme-icon .material-icons-round {
  font-size: 14px;
  color: white;
}

.extreme-icon.max { background: var(--tide-exceptional); }
.extreme-icon.min { background: var(--tide-exceptional-low); }

.extreme-value {
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
}

.extreme-time {
  color: var(--text-tertiary);
  margin-left: auto;
}

.forecast-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--surface-border);
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.forecast-meta-item {
  display: flex;
  align-items: center;
  gap: 4px;
}

.forecast-meta-item .material-icons-round {
  font-size: 16px;
}

.forecast-lunar {
  margin-left: auto;
  font-size: 1.1rem;
}

/* ===== Monthly Charts Grid ===== */
.months-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
}

.month-card {
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 20px;
  text-align: center;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: var(--transition);
  border: 2px solid transparent;
}

.month-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
  border-color: var(--primary);
}

.month-card.current {
  border-color: var(--primary);
  background: linear-gradient(135deg, rgba(21,101,192,0.05), rgba(38,166,154,0.05));
}

.month-card .material-icons-round {
  font-size: 32px;
  color: var(--primary);
  margin-bottom: 8px;
}

.month-name {
  font-weight: 600;
  font-size: 0.9rem;
}

/* ===== PDF Viewer ===== */
.pdf-viewer {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--bg);
  display: flex;
  flex-direction: column;
}

.pdf-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--surface-border);
  font-weight: 600;
}

.pdf-frame {
  flex: 1;
  border: none;
  width: 100%;
}

/* ===== Data Menu ===== */
.data-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
}

.data-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: var(--transition);
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text);
}

.data-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
  border-color: var(--primary);
}

.data-icon {
  font-size: 32px !important;
  color: var(--primary);
}

/* ===== Data Detail ===== */
.detail-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.detail-header h2 {
  font-size: 1.1rem;
  font-weight: 700;
}

.detail-content {
  animation: fadeSlideUp 0.3s ease;
}

/* Station list in detail views */
.station-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 12px;
}

.station-item {
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition);
}

.station-item:hover {
  box-shadow: var(--shadow-lg);
}

.station-item-name {
  font-weight: 600;
  font-size: 0.9rem;
}

.station-item-time {
  font-size: 0.75rem;
  color: var(--text-tertiary);
}

.station-item-value {
  font-size: 1.4rem;
  font-weight: 800;
  font-family: 'JetBrains Mono', monospace;
}

.station-item-unit {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-secondary);
}

.station-item-extra {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* Hero card for data sections */
.hero-card {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: var(--radius);
  padding: 28px;
  color: white;
  margin-bottom: 20px;
  box-shadow: var(--shadow-lg);
}

.hero-card h3 {
  font-size: 0.85rem;
  font-weight: 500;
  opacity: 0.85;
  margin-bottom: 4px;
}

.hero-values {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
}

.hero-stat {
  text-align: center;
}

.hero-stat-value {
  font-size: 2.2rem;
  font-weight: 800;
  font-family: 'JetBrains Mono', monospace;
  line-height: 1.2;
}

.hero-stat-label {
  font-size: 0.75rem;
  opacity: 0.8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ===== Lunar Calendar ===== */
.lunar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 10px;
}

.lunar-item {
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 14px;
  text-align: center;
  box-shadow: var(--shadow);
}

.lunar-emoji {
  font-size: 2rem;
  margin-bottom: 4px;
}

.lunar-date {
  font-size: 0.8rem;
  font-weight: 600;
}

.lunar-type {
  font-size: 0.7rem;
  color: var(--text-secondary);
}

/* ===== Extremes ===== */
.extremes-controls {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  align-items: center;
}

.extremes-controls input[type="date"],
.extremes-controls select {
  padding: 8px 12px;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
}

.extremes-controls button {
  padding: 8px 20px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: var(--radius-xs);
  cursor: pointer;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  transition: var(--transition);
}

.extremes-controls button:hover {
  background: var(--primary-dark);
}

.extremes-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.extremes-table th,
.extremes-table td {
  padding: 12px 16px;
  text-align: left;
  font-size: 0.85rem;
}

.extremes-table th {
  background: var(--primary);
  color: white;
  font-weight: 600;
}

.extremes-table tr:nth-child(even) {
  background: var(--surface-hover);
}

.extremes-table .max-val { color: var(--tide-exceptional); font-weight: 700; }
.extremes-table .min-val { color: var(--tide-exceptional-low); font-weight: 700; }

/* ===== Map ===== */
.map-container {
  height: 500px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

/* ===== Emergency ===== */
.emergency-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}

.emergency-card {
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 20px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 16px;
}

.emergency-card .material-icons-round {
  font-size: 36px;
  color: var(--tide-exceptional);
}

.emergency-name {
  font-weight: 700;
  margin-bottom: 2px;
}

.emergency-number {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--primary);
  font-family: 'JetBrains Mono', monospace;
}

.emergency-number a {
  color: inherit;
  text-decoration: none;
}

.emergency-number a:hover {
  text-decoration: underline;
}

/* ===== Settings ===== */
.settings-list {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.setting-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--surface-border);
}

.setting-item:last-child { border-bottom: none; }

.setting-label {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
}

.setting-label .material-icons-round {
  color: var(--primary);
}

.setting-select {
  padding: 8px 12px;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  min-width: 180px;
}

/* Toggle Switch */
.toggle {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 28px;
}

.toggle input { opacity: 0; width: 0; height: 0; }

.toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: var(--text-tertiary);
  border-radius: 28px;
  transition: var(--transition);
}

.toggle-slider::before {
  content: '';
  position: absolute;
  height: 22px;
  width: 22px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: var(--transition);
}

.toggle input:checked + .toggle-slider {
  background: var(--primary);
}

.toggle input:checked + .toggle-slider::before {
  transform: translateX(20px);
}

/* ===== About ===== */
.about-content {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
  box-shadow: var(--shadow);
}

.about-logo {
  margin-bottom: 20px;
}

.about-logo-img {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  object-fit: contain;
  margin-bottom: 8px;
  box-shadow: var(--shadow-lg);
}

.about-icon {
  font-size: 56px !important;
  color: var(--primary);
  margin-bottom: 8px;
}

.about-logo h3 {
  font-size: 1.3rem;
  font-weight: 800;
}

.about-version {
  color: var(--text-tertiary);
  font-size: 0.85rem;
}

.about-desc {
  color: var(--text-secondary);
  margin-bottom: 20px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.about-links {
  margin-bottom: 20px;
}

.about-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: var(--radius-xs);
  transition: var(--transition);
}

.about-link:hover {
  background: var(--surface-hover);
}

.about-credits {
  font-size: 0.8rem;
  color: var(--text-tertiary);
}

/* ===== Skeletons ===== */
.skeleton {
  background: linear-gradient(90deg, var(--surface-hover) 25%, var(--surface) 37%, var(--surface-hover) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
  border-radius: var(--radius-sm);
}

.skeleton-card {
  height: 200px;
  border-radius: var(--radius);
}

.skeleton-line {
  height: 16px;
  margin-bottom: 8px;
  border-radius: 4px;
}

.skeleton-line.short { width: 60%; }

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--text-tertiary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-secondary);
}

/* ===== History Chart in detail ===== */
.history-chart-container {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  margin-bottom: 20px;
  height: 280px;
  position: relative;
}

/* ===== Wind specific ===== */
.wind-direction {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--surface-hover);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary);
}

/* ===== Beaufort Scale Badge ===== */
.beaufort-badge {
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 600;
  color: white;
}

/* ===== Footer ===== */
.app-footer {
  background: var(--surface);
  border-top: 1px solid var(--surface-border);
  padding: 40px 20px 32px;
  margin-top: 20px;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

.footer-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 12px;
}

.footer-logo-img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  object-fit: contain;
}

.footer-brand {
  font-size: 1.1rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.footer-desc {
  color: var(--text-secondary);
  font-size: 0.85rem;
  max-width: 500px;
  margin: 0 auto 16px;
  line-height: 1.5;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--primary);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: var(--radius-xs);
  transition: var(--transition);
}

.footer-links a:hover {
  background: var(--surface-hover);
}

.footer-links a .material-icons-round {
  font-size: 16px;
}

/* App Store Banner */
.footer-app-banner {
  background: linear-gradient(135deg, rgba(21,101,192,0.06), rgba(38,166,154,0.06));
  border: 1px solid var(--surface-border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
}

[data-theme="dark"] .footer-app-banner {
  background: linear-gradient(135deg, rgba(21,101,192,0.12), rgba(38,166,154,0.12));
}

.footer-app-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 14px;
}

.store-badges {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--text);
  color: var(--bg);
  border-radius: 10px;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  transition: var(--transition);
  box-shadow: var(--shadow);
}

.store-badge:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  opacity: 0.9;
}

.store-badge svg {
  flex-shrink: 0;
}

.footer-credits {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-bottom: 8px;
}

.footer-copy {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  border-top: 1px solid var(--surface-border);
  padding-top: 12px;
}

/* ===== Date filter controls ===== */
.filter-controls {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  align-items: center;
}

.filter-controls label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.filter-controls input[type="date"] {
  padding: 8px 12px;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
}

.filter-controls button {
  padding: 8px 20px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: var(--radius-xs);
  cursor: pointer;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  transition: var(--transition);
}

.filter-controls button:hover {
  background: var(--primary-dark);
}
