/*
 * Aurora Hunter stylesheet
 *
 * Cool palette to match the night sky and aurora tones.
 * Clean layout that works on both mobile and desktop.
 */

/* CSS variables make it easy to adjust the palette consistently */
:root {
  --primary-color: #48a9a6; /* Aurora green */
  --secondary-color: #132743; /* Midnight blue */
  --light-color: #f5f9fa; /* Light background */
  --card-bg: rgba(255, 255, 255, 0.1); /* Semi-transparent card background */
  --card-border: rgba(255, 255, 255, 0.3);
  --text-light: #ffffff;
  --text-dark: #333333;
  --shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  font-family: "Helvetica Neue", Arial, sans-serif;
}

/* Basic reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--secondary-color);
  color: var(--text-dark);
  line-height: 1.6;
  font-size: 16px;
}

/* Sidebar menu */
.menu-button {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 1100;
  background: rgba(0, 0, 0, 0.6);
  color: var(--light-color);
  border: 1px solid var(--card-border);
  border-radius: 6px;
  padding: 0.5rem 0.7rem;
  font-size: 1.1rem;
  cursor: pointer;
  box-shadow: var(--shadow);
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  height: 100%;
  width: 220px;
  background: rgba(10, 16, 36, 0.95);
  border-right: 1px solid var(--card-border);
  padding: 4rem 1rem 1rem;
  box-shadow: 4px 0 15px rgba(0,0,0,0.4);
  z-index: 1050;
  transform: translateX(0);
}

.sidebar.hidden {
  transform: translateX(-110%);
}

.sidebar nav {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.sidebar a {
  color: var(--light-color);
  text-decoration: none;
  font-weight: 600;
  padding: 0.4rem 0.2rem;
}

.sidebar a:hover {
  color: var(--primary-color);
}
h1, h2, h3 {
  font-weight: 600;
  margin-bottom: 0.5rem;
}

h1 {
  font-size: 2.5rem;
  color: var(--text-light);
}

h2 {
  font-size: 1.8rem;
  color: var(--primary-color);
  text-align: center;
  margin-bottom: 1rem;
}

.section-desc {
  text-align: center;
  margin-bottom: 1.5rem;
  color: var(--light-color);
}

/* Hero section */
.hero {
  position: relative;
  height: 60vh;
  width: 100%;
  overflow: hidden;
}

/* ... (omitting lines not in this chunk selection, waiting for next tool call if needed? No, I can target specific blocks) */
/* Actually, .hero is around line 111, .blog-hero is around line 775. I should use multi_replace. */

.hero-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.9) saturate(1.6) contrast(1.2);
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(0,0,0,0.4), rgba(0,0,0,0.8));
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 0 1rem;
}

.hero-content p {
  font-size: 1.2rem;
  color: var(--light-color);
  margin-top: 0.5rem;
}

.oval-card {
  margin-top: 1.5rem;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 1rem;
  width: min(900px, 100%);
  box-shadow: var(--shadow);
}

.oval-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
  color: var(--light-color);
}

.oval-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.oval-image-wrap {
  width: 100%;
  background: rgba(0, 0, 0, 0.35);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--card-border);
  position: relative;
  height: auto;
}

.oval-image-wrap img {
  width: 100%;
  max-height: 380px;
  display: block;
  object-fit: contain;
  background: rgba(0, 0, 0, 0.25);
  transform-origin: center center;
  transition: transform 0.05s linear;
  cursor: grab;
}

.oval-image-wrap img.dragging {
  cursor: grabbing;
  transition: none;
}

/* Make auroral oval card span grid width when in the space weather grid */
.space-weather-grid .oval-card {
  grid-column: 1 / -1;
  width: 100%;
  margin-top: 0;
}

/* Moon phase card */
.moon-card {
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 0.8rem;
  color: var(--light-color);
  text-align: center;
  box-shadow: var(--shadow);
}

.moon-card h4 {
  margin-bottom: 0.4rem;
  color: var(--primary-color);
}

.moon-visual {
  display: flex;
  justify-content: center;
  margin: 0.5rem 0;
}

.moon-label {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.85);
  margin-top: 0.25rem;
  font-weight: 500;
}

/* Ensure moon label overrides generic card paragraph styling */
.card .moon-label {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.85);
  margin-top: 0.25rem;
  font-weight: 500;
}

.moon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle at 28% 28%, #ffffff 45%, #f2f7fb 70%, #cfd8e3 100%);
  position: relative;
  overflow: hidden;
  box-shadow:
    0 0 14px rgba(255,255,255,0.4),
    inset 0 0 10px rgba(0,0,0,0.35),
    0 0 10px rgba(0,0,0,0.15);
  --moon-offset: 0%;
}

.moon::after {
  content: '';
  position: absolute;
  inset: 0;
  background: #0b1630;
  transform: translateX(var(--moon-offset));
  box-shadow: 0 0 12px rgba(0,0,0,0.6);
}

.label {
  font-size: 0.9rem;
  letter-spacing: 0.02em;
  color: var(--light-color);
  opacity: 0.9;
}

/* Match core1 card title sizing for auroral oval label */
.oval-card .label {
  font-size: 1rem;
  color: var(--primary-color);
  letter-spacing: 0.01em;
  opacity: 1;
}

main {
  padding: 2rem 1rem;
}

/* Buttons */
.cta-button,
.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.4rem;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  background-color: var(--primary-color);
  color: var(--text-light);
  font-weight: 600;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.2s ease;
}

.cta-button:hover,
.primary-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4);
  background-color: #3b8c89;
}

.cta-button:active,
.primary-button:active {
  transform: translateY(0);
}

.primary-button.small {
  padding: 0.55rem 1rem;
  font-size: 0.95rem;
}

/* Shared section styling */
.section {
  margin-bottom: 3rem;
  backdrop-filter: blur(4px);
}

/* Card grid layout */
.space-weather-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  max-width: 1000px;
  margin: 0 auto;
}

.card {
  background-color: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 1rem;
  color: var(--light-color);
  text-align: center;
  backdrop-filter: blur(5px);
  box-shadow: var(--shadow);
}

.card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

/* Slightly smaller card titles within the space weather section */
#core1 .card h3 {
  font-size: 1rem;
}

.card p {
  font-size: 1.4rem;
  font-weight: bold;
}

.gauge {
  margin-top: 0.6rem;
}

.gauge-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  overflow: hidden;
}

.gauge-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #48a9a6, #f7d046, #f45b69);
  transition: width 0.25s ease;
}

.gauge-label {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.85);
  margin-top: 0.25rem;
}

.gauge-range {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.75);
  margin-top: 0.15rem;
}

.space-weather-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  justify-content: center;
  margin: 0 auto 1.5rem auto;
  max-width: 900px;
  color: var(--light-color);
}

.status-text {
  font-size: 0.95rem;
  color: var(--light-color);
  opacity: 0.9;
}

.status-text.error {
  color: #ffcdd2;
}

/* Dropdown styles */
select {
  padding: 0.6rem 1rem;
  font-size: 1rem;
  border-radius: 8px;
  border: 1px solid var(--card-border);
  background-color: var(--card-bg);
  color: var(--light-color);
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  display: block;
}

select option {
  background-color: var(--secondary-color);
  color: var(--light-color);
}

/* Utility class to hide elements */
.hidden {
  display: none;
}

/* Info container styling */
.info-container {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  color: var(--light-color);
}

.info-card {
  background-color: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 1rem;
  box-shadow: var(--shadow);
}

.blog-article {
  max-width: 980px;
  margin: 0 auto;
}

.blog-article h2 {
  margin-bottom: 1.5rem;
}

.blog-article .info-card {
  padding: 1.25rem 1.5rem;
  line-height: 1.75;
  background: linear-gradient(145deg, rgba(19, 39, 67, 0.82), rgba(19, 39, 67, 0.6));
  border: none;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
}

.blog-article .info-card h3 {
  font-size: 1.2rem;
  margin: 0.25rem 0 0.6rem;
}

.blog-article .info-card h4 {
  font-size: 1.05rem;
  margin: 0.6rem 0 0.4rem;
  color: var(--primary-color);
}

.blog-article p {
  margin: 0.4rem 0 0.8rem;
  color: var(--light-color);
}

.blog-article ul,
.blog-article ol {
  padding-left: 1.2rem;
  margin: 0.4rem 0 0.8rem;
  color: var(--light-color);
}

.blog-article ul li,
.blog-article ol li {
  margin: 0.25rem 0;
}

.blog-article table {
  margin-top: 0.75rem;
}

.blog-article table.weather-table th {
  background: rgba(72, 169, 166, 0.25);
}

.blog-article table.weather-table tr:nth-child(odd) td {
  background: rgba(255, 255, 255, 0.03);
}

.blog-entry {
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.35);
  padding: 0.75rem 1rem;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
}

.blog-entry summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

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

.blog-entry-date {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.65);
  white-space: nowrap;
}

.blog-entry summary::after {
  content: '▸';
  font-size: 1rem;
  color: var(--light-color);
  transition: transform 0.2s ease;
  margin-left: 0.5rem;
}

.blog-entry[open] summary::after {
  transform: rotate(90deg);
}

.blog-entry-header h3,
.blog-entry-header h2 {
  margin: 0;
  text-align: left;
  font-size: 1.5rem;
  color: var(--primary-color);
}

.blog-entry-teaser {
  margin: 0.2rem 0 0;
  color: rgba(255,255,255,0.8);
}

.blog-entry-body {
  margin-top: 0.8rem;
}

.blog-entry-body .info-card {
  border-left: 3px solid var(--primary-color);
}

.info-card h3 {
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.info-card p {
  color: var(--light-color);
}

.info-card a {
  color: #6fd1cd;
  text-decoration: underline;
  font-weight: 600;
  transition: color 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.info-card a:hover,
.info-card a:focus {
  color: #9ae5e1;
}

.info-card a::before {
  content: "";
  width: 14px;
  height: 14px;
  display: inline-block;
  background-repeat: no-repeat;
  background-size: 14px 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236fd1cd' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 14L4 20'/%3E%3Cpath d='M14 10l6-6'/%3E%3Cpath d='M15 5h5v5'/%3E%3Cpath d='M9 19H4v-5'/%3E%3C/svg%3E");
}

/* FAQ accordion tweaks */
details.info-card {
  position: relative;
  padding-right: 2rem;
}

details.info-card summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

details.info-card summary::after {
  content: '▸';
  font-size: 1rem;
  color: var(--light-color);
  transition: transform 0.2s ease;
  margin-left: 0.5rem;
}

details.info-card[open] summary::after {
  transform: rotate(90deg);
}

table.weather-table {
  width: 100%;
  border-collapse: collapse;
  color: var(--light-color);
}

table.weather-table th,
table.weather-table td {
  padding: 0.5rem;
  border: 1px solid var(--card-border);
  text-align: center;
}

table.weather-table th {
  background-color: rgba(72, 169, 166, 0.3);
}

table.weather-table td {
  background-color: rgba(255, 255, 255, 0.05);
}

footer {
  text-align: center;
  padding: 1rem 0;
  background-color: rgba(0,0,0,0.4);
  color: var(--light-color);
}

.step-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  max-width: 1000px;
  margin: 0 auto;
}

.meta-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.5rem;
  padding: 0;
}

.meta-list li {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
  color: var(--light-color);
}

.meta-list strong {
  display: block;
  margin-bottom: 0.2rem;
  color: var(--primary-color);
}

.info-trigger {
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.info-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.info-modal.hidden {
  display: none;
}

.info-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(2px);
}

.info-modal-content {
  position: relative;
  background: rgba(10, 16, 36, 0.95);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 1.5rem;
  max-width: 480px;
  width: 90%;
  color: var(--light-color);
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  z-index: 1;
}

.info-modal-content h3 {
  margin-bottom: 0.6rem;
  color: var(--primary-color);
}

.info-modal-content p {
  line-height: 1.5;
  font-size: 0.95rem;
}

.close-btn {
  position: absolute;
  right: 1rem;
  top: 1rem;
}

@media (max-width: 600px) {
  h1 {
    font-size: 1.8rem;
  }
  .hero {
    height: 60vh;
  }
  .card p {
    font-size: 1.2rem;
  }

  select {
    font-size: 0.9rem;
  }
}

/* Blog specific styles */
.blog-hero {
  height: 30vh; /* Shorter hero for blog */
}

.blog-hero .hero-content {
  justify-content: flex-end;
  padding-bottom: 3rem;
}

.blog-card {
  padding: 0; /* Remove padding from card to let image flush with edges */
  overflow: hidden;
  text-align: left;
  display: flex;
  flex-direction: column;
}

.blog-img-wrap {
  width: 100%;
  height: 200px;
  overflow: hidden;
  position: relative;
}

.blog-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.blog-card:hover .blog-img-wrap img {
  transform: scale(1.05); /* Zoom effect on hover */
}

.blog-content {
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-date {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 0.5rem;
  display: block;
}

.blog-card h3 {
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
  color: var(--primary-color);
}

.blog-card p {
  font-size: 1rem;
  color: var(--light-color);
  margin-bottom: 1.5rem;
  font-weight: normal;
  line-height: 1.5;
}

.blog-card .primary-button {
  margin-top: auto;
  align-self: flex-start;
}

/* Article content styling for better readability */
.article-content {
  font-family: 'Inter', "Helvetica Neue", Arial, sans-serif;
  line-height: 1.8;
  color: var(--light-color);
  max-width: 800px;
  margin: 0 auto;
}

.article-content .tldr {
  background: rgba(72, 169, 166, 0.1);
  border: 1px solid rgba(72, 169, 166, 0.35);
  border-radius: 10px;
  padding: 1rem 1.2rem;
  margin-bottom: 1.2rem;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
}

.article-content .tldr ul {
  margin: 0.4rem 0 0;
  padding-left: 1.1rem;
}

.article-content .tldr li {
  margin: 0.25rem 0;
}

.article-content h2 {
  font-size: 2rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
  text-align: left;
  color: var(--primary-color);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 0.5rem;
}

.article-content h3 {
  font-size: 1.6rem;
  margin-top: 1.6rem;
  margin-bottom: 0.7rem;
  color: var(--primary-color);
  font-weight: 800;
}

.article-content h4 {
  font-size: 1.2rem;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.article-content p {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
}

.article-content ul,
.article-content ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.article-content li {
  margin-bottom: 0.5rem;
  padding-left: 0.5rem;
}

.article-caption {
  text-align: center;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
  margin-top: -1.5rem;
  margin-bottom: 2rem;
  font-style: italic;
}

.article-content strong {
  color: var(--text-light);
}

.article-content .weather-table {
  margin-top: 1rem;
  margin-bottom: 2rem;
  font-size: 1rem;
}

.article-image {
  width: 100%;
  height: auto;
  margin: 1.4rem 0;
  text-align: center;
  box-shadow: none;
  border: none;
}

.article-image img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: none;
  border: none;
}
