/* ============================================
   DAILY MESSAGE - Victorian Aesthetic Styles
   ============================================ */

/* CSS Variables */
:root {
  /* Color Palette */
  --primary: #6B0F1A;
  --primary-dark: #4A0A12;
  --primary-light: #8B1F2A;
  --secondary: #C9A961;
  --secondary-light: #E5D5A8;
  --secondary-dark: #A68B4B;
  --background: #F4EFE4;
  --background-alt: #EDE7D9;
  --text: #2C2C2C;
  --text-light: #4A4A4A;
  --accent: #2C4A2F;
  --accent-light: #3D6B42;
  --inactive: #C0C0C0;
  --white: #FFFEF9;
  --shadow: rgba(43, 15, 18, 0.15);

  /* Typography */
  --font-quote: 'IM Fell DW Pica', Georgia, serif;
  --font-author: 'Cormorant Garamond', Georgia, serif;
  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body: 'Crimson Text', Georgia, serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --space-xxl: 5rem;

  /* Transitions */
  --transition: all 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--background);
  color: var(--text);
  line-height: 1.7;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* Background Pattern */
.bg-pattern {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  background-image:
    radial-gradient(circle at 20% 80%, rgba(107, 15, 26, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(201, 169, 97, 0.05) 0%, transparent 50%),
    url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 5 L35 15 L30 25 L25 15 Z' fill='%23C9A961' fill-opacity='0.03'/%3E%3C/svg%3E");
}

/* ============================================
   HEADER
   ============================================ */
.header {
  text-align: center;
  padding: var(--space-lg) var(--space-lg) var(--space-md);
  position: relative;
  background: linear-gradient(180deg, var(--background-alt) 0%, var(--background) 100%);
  border-bottom: 1px solid var(--secondary-light);
}


.site-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  color: var(--primary);
  letter-spacing: 0.08em;
  text-shadow: 1px 1px 2px var(--shadow);
  margin-bottom: var(--space-xs);
  cursor: pointer;
  transition: var(--transition);
  display: inline-block;
}

.site-title:hover {
  color: var(--primary-dark);
  transform: scale(1.02);
  text-shadow: 2px 2px 4px var(--shadow);
}

.site-subtitle {
  font-family: var(--font-body);
  font-size: 1rem;
  font-style: italic;
  color: var(--text-light);
  letter-spacing: 0.15em;
  margin-bottom: var(--space-sm);
}

.current-date {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--secondary-dark);
  letter-spacing: 0.1em;
  padding: var(--space-xs) var(--space-md);
  display: inline-block;
  border-top: 1px solid var(--secondary);
  border-bottom: 1px solid var(--secondary);
  margin-top: var(--space-sm);
}

/* ============================================
   MINI CALENDAR
   ============================================ */
.mini-calendar {
  flex: 0 0 280px;
  background: var(--white);
  border: 1px solid var(--secondary-light);
  border-radius: 8px;
  box-shadow: 0 4px 15px var(--shadow);
  font-size: 0.8rem;
  overflow: hidden;
}

.mini-calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 1rem;
  background: var(--primary);
  color: var(--secondary-light);
}

.mini-month {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.05em;
}

.mini-nav-btn {
  background: transparent;
  border: none;
  color: var(--secondary-light);
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  font-size: 0.8rem;
  opacity: 0.8;
  transition: var(--transition);
}

.mini-nav-btn:hover:not(:disabled) {
  opacity: 1;
}

.mini-nav-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.mini-calendar-grid {
  padding: 0.75rem;
}

.mini-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  color: var(--text-light);
  font-weight: 600;
  font-size: 0.75rem;
  margin-bottom: 0.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--secondary-light);
}

.mini-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.mini-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  color: var(--text);
  border-radius: 4px;
  cursor: default;
  transition: var(--transition);
}

.mini-day.empty {
  visibility: hidden;
}

.mini-day.has-quote {
  cursor: pointer;
  color: var(--primary);
  font-weight: 600;
}

.mini-day.has-quote:hover {
  background: var(--secondary-light);
}

.mini-day.today {
  background: var(--secondary);
  color: var(--primary-dark);
  font-weight: 700;
}

.mini-day.selected {
  background: var(--primary);
  color: var(--white);
}

.mini-day.future,
.mini-day.no-quote {
  color: var(--inactive);
}

/* ============================================
   MAIN CONTENT
   ============================================ */
.main-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--space-xl) var(--space-lg);
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  min-height: 60vh;
}

/* Scripture Card (Above Quote) */
.scripture-card {
  width: 100%;
  max-width: 900px;
  background: linear-gradient(135deg, var(--white) 0%, var(--background) 100%);
  border: 1px solid var(--secondary);
  border-radius: 6px;
  padding: var(--space-md) var(--space-lg);
  margin-bottom: var(--space-lg);
  text-align: center;
  position: relative;
  display: none;
}

.scripture-card.visible {
  display: block;
  animation: fadeSlideDown 0.5s ease forwards;
}

@keyframes fadeSlideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.scripture-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.scripture-ref {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.08em;
}

.scripture-divider {
  color: var(--secondary);
}

.translation-badge {
  font-family: var(--font-body);
  font-size: 0.7rem;
  color: var(--secondary-dark);
  letter-spacing: 0.1em;
  padding: 0.15rem 0.4rem;
  border: 1px solid var(--secondary);
  border-radius: 3px;
}

.scripture-text {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
  font-style: italic;
}

/* Quote Container */
.quote-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  min-width: 0;
  text-align: center;
}

.quote-frame {
  position: relative;
  background: linear-gradient(135deg, var(--white) 0%, #FDFBF7 100%);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 4px solid var(--primary);
  padding: var(--space-xl) var(--space-lg);
  box-shadow:
    0 8px 40px var(--shadow),
    inset 0 0 100px rgba(107, 15, 26, 0.03),
    inset 0 0 200px rgba(201, 169, 97, 0.05);
  width: 100%;
  box-sizing: border-box;
  overflow: visible;
  min-height: fit-content;
  transition: background-image 0.5s ease;
}

/* Photo Background Container (img-based approach) */
.photo-bg-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
  pointer-events: none;
}

.photo-bg-image {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 1;
}

.photo-bg-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.25);
  pointer-events: none;
  z-index: 2;
}

/* Photo Background Mode */
.quote-frame.photo-background {
  /* Force transparent background */
  background: none !important;
  background-color: transparent !important;
  background-image: none !important;
  /* Remove inset box-shadows that could create overlay effect */
  box-shadow: 0 8px 40px var(--shadow) !important;
}

.quote-frame.photo-background::before,
.quote-frame.photo-background::after {
  /* Hide the default borders when photo is active */
  display: none !important;
}

.quote-frame.photo-background .quote-inner {
  position: relative;
  z-index: 10;
  /* Remove background panel - text goes directly on image */
  background: none !important;
  background-color: transparent !important;
  backdrop-filter: none;
}

.quote-frame.photo-background .quote-text {
  /* Strong text shadow and outline for readability on any background */
  color: var(--white);
  text-shadow:
    -1px -1px 0 rgba(0, 0, 0, 0.8),
    1px -1px 0 rgba(0, 0, 0, 0.8),
    -1px 1px 0 rgba(0, 0, 0, 0.8),
    1px 1px 0 rgba(0, 0, 0, 0.8),
    0 0 10px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(0, 0, 0, 0.6),
    2px 2px 4px rgba(0, 0, 0, 0.9);
  font-weight: 500;
}

.quote-frame.photo-background .quote-author {
  /* Strong text shadow for readability */
  color: var(--white);
  text-shadow:
    -1px -1px 0 rgba(0, 0, 0, 0.8),
    1px -1px 0 rgba(0, 0, 0, 0.8),
    -1px 1px 0 rgba(0, 0, 0, 0.8),
    1px 1px 0 rgba(0, 0, 0, 0.8),
    0 0 8px rgba(0, 0, 0, 0.7),
    0 0 15px rgba(0, 0, 0, 0.5);
  font-weight: 600;
}

/* Scripture text within quote frame when photo background is enabled */
.quote-frame.photo-background .scripture-container,
.quote-frame.photo-background [class*="scripture"] {
  /* Strong text shadow and background for scripture readability */
  color: var(--white) !important;
  text-shadow:
    -2px -2px 0 rgba(0, 0, 0, 0.9),
    2px -2px 0 rgba(0, 0, 0, 0.9),
    -2px 2px 0 rgba(0, 0, 0, 0.9),
    2px 2px 0 rgba(0, 0, 0, 0.9),
    0 0 12px rgba(0, 0, 0, 0.9),
    0 0 24px rgba(0, 0, 0, 0.7),
    3px 3px 6px rgba(0, 0, 0, 0.95);
  font-weight: 600;
}

.quote-frame.photo-background .scripture-ref,
.quote-frame.photo-background [class*="scripture-ref"] {
  color: var(--white) !important;
  text-shadow:
    -2px -2px 0 rgba(0, 0, 0, 0.9),
    2px -2px 0 rgba(0, 0, 0, 0.9),
    -2px 2px 0 rgba(0, 0, 0, 0.9),
    2px 2px 0 rgba(0, 0, 0, 0.9),
    0 0 12px rgba(0, 0, 0, 0.9),
    0 0 24px rgba(0, 0, 0, 0.7),
    3px 3px 6px rgba(0, 0, 0, 0.95);
  font-weight: 700;
  font-size: 1.1rem !important;
}

.quote-frame.photo-background .scripture-text,
.quote-frame.photo-background [class*="scripture-text"] {
  color: var(--white) !important;
  text-shadow:
    -2px -2px 0 rgba(0, 0, 0, 0.9),
    2px -2px 0 rgba(0, 0, 0, 0.9),
    -2px 2px 0 rgba(0, 0, 0, 0.9),
    2px 2px 0 rgba(0, 0, 0, 0.9),
    0 0 12px rgba(0, 0, 0, 0.9),
    0 0 24px rgba(0, 0, 0, 0.7),
    3px 3px 6px rgba(0, 0, 0, 0.95);
  font-weight: 600;
  font-size: 1.05rem !important;
  line-height: 1.8 !important;
}

.quote-frame.photo-background .quote-mark {
  opacity: 0.4;
  color: var(--white);
  text-shadow:
    -1px -1px 0 rgba(0, 0, 0, 0.6),
    1px -1px 0 rgba(0, 0, 0, 0.6),
    -1px 1px 0 rgba(0, 0, 0, 0.6),
    1px 1px 0 rgba(0, 0, 0, 0.6),
    0 0 10px rgba(0, 0, 0, 0.5);
}

.quote-frame.photo-background .quote-divider::before,
.quote-frame.photo-background .quote-divider::after {
  background: linear-gradient(90deg, transparent, var(--white), var(--white), transparent);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  opacity: 0.9;
}

.quote-frame.photo-background .divider-ornament {
  color: var(--white);
  text-shadow:
    -1px -1px 0 rgba(0, 0, 0, 0.8),
    1px -1px 0 rgba(0, 0, 0, 0.8),
    -1px 1px 0 rgba(0, 0, 0, 0.8),
    1px 1px 0 rgba(0, 0, 0, 0.8),
    0 0 8px rgba(0, 0, 0, 0.7);
}

.quote-frame.photo-background .corner-ornament {
  border-color: var(--white);
  opacity: 0.8;
}

.quote-frame.photo-background .corner-ornament::before {
  color: var(--white);
  opacity: 0.9;
  text-shadow:
    -1px -1px 0 rgba(0, 0, 0, 0.6),
    1px -1px 0 rgba(0, 0, 0, 0.6),
    -1px 1px 0 rgba(0, 0, 0, 0.6),
    1px 1px 0 rgba(0, 0, 0, 0.6);
}

.quote-frame.photo-background .side-ornament {
  opacity: 0.6;
  background: linear-gradient(180deg, transparent, var(--white), var(--white), transparent);
}

.quote-frame.photo-background .side-ornament::before,
.quote-frame.photo-background .side-ornament::after {
  color: var(--white);
  text-shadow:
    -1px -1px 0 rgba(0, 0, 0, 0.6),
    1px -1px 0 rgba(0, 0, 0, 0.6),
    -1px 1px 0 rgba(0, 0, 0, 0.6),
    1px 1px 0 rgba(0, 0, 0, 0.6);
}


.quote-frame::before {
  content: '';
  position: absolute;
  inset: 12px;
  border: 2px solid var(--secondary);
  pointer-events: none;
  box-shadow: inset 0 0 20px rgba(201, 169, 97, 0.1);
}

.quote-frame::after {
  content: '';
  position: absolute;
  inset: 20px;
  border: 1px solid rgba(201, 169, 97, 0.3);
  pointer-events: none;
}

/* Corner Ornaments */
.corner-ornament {
  position: absolute;
  width: 50px;
  height: 50px;
  border: 3px solid var(--secondary);
  z-index: 5;
}

.corner-ornament::before {
  content: '❧';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 1.2rem;
  color: var(--secondary);
  opacity: 0.6;
}

.corner-ornament.top-left {
  top: -3px;
  left: -3px;
  border-right: none;
  border-bottom: none;
  border-radius: 0 0 100% 0;
}

.corner-ornament.top-right {
  top: -3px;
  right: -3px;
  border-left: none;
  border-bottom: none;
  border-radius: 0 0 0 100%;
}

.corner-ornament.bottom-left {
  bottom: -3px;
  left: -3px;
  border-right: none;
  border-top: none;
  border-radius: 0 100% 0 0;
}

.corner-ornament.bottom-right {
  bottom: -3px;
  right: -3px;
  border-left: none;
  border-top: none;
  border-radius: 100% 0 0 0;
}

/* Side Ornaments */
.side-ornament {
  position: absolute;
  width: 3px;
  height: 120px;
  background: linear-gradient(180deg, transparent, var(--secondary), var(--secondary-dark), var(--secondary), transparent);
  z-index: 4;
  opacity: 0.6;
}

.side-ornament.left {
  left: 30px;
  top: 50%;
  transform: translateY(-50%);
}

.side-ornament.right {
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
}

.side-ornament::before,
.side-ornament::after {
  content: '✦';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.8rem;
  color: var(--secondary);
}

.side-ornament::before {
  top: -15px;
}

.side-ornament::after {
  bottom: -15px;
}

.quote-inner {
  position: relative;
  padding: var(--space-lg);
  padding-bottom: var(--space-xl);
  background:
    radial-gradient(circle at 20% 30%, rgba(201, 169, 97, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(107, 15, 26, 0.02) 0%, transparent 50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  box-sizing: border-box;
  min-height: fit-content;
}

.quote-mark {
  font-family: Georgia, serif;
  font-size: 6rem;
  color: var(--secondary);
  opacity: 0.2;
  line-height: 0;
  position: absolute;
}

.quote-mark.opening {
  top: 0;
  left: 0;
}

.quote-mark.closing {
  bottom: 4rem;
  right: 0;
  position: absolute;
}

.quote-text {
  font-family: var(--font-quote);
  font-size: clamp(1.8rem, 5vw, 3rem);
  font-weight: 400;
  font-style: normal;
  color: var(--primary-dark);
  line-height: 1.5;
  letter-spacing: 0.03em;
  padding: var(--space-lg) var(--space-md);
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
  text-shadow:
    0.5px 0.5px 1px rgba(107, 15, 26, 0.1),
    0 0 2px rgba(201, 169, 97, 0.1);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.quote-divider {
  margin: var(--space-lg) auto var(--space-md);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  position: relative;
}

.quote-divider::before,
.quote-divider::after {
  content: '';
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--secondary), var(--secondary-dark), var(--secondary), transparent);
  box-shadow: 0 1px 2px rgba(201, 169, 97, 0.3);
}

.divider-ornament {
  color: var(--secondary-dark);
  font-size: 1.5rem;
  text-shadow: 0 1px 2px rgba(201, 169, 97, 0.3);
}

.quote-author {
  font-family: var(--font-author);
  font-size: 1.4rem;
  font-style: italic;
  font-weight: 500;
  color: var(--text);
  letter-spacing: 0.05em;
  display: block;
  text-align: center;
  width: 100%;
  margin-top: var(--space-md);
}

/* Quote Controls Container (Above quote, right aligned) */
.quote-controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-xs);
  margin-bottom: var(--space-sm);
  width: 100%;
  max-width: 1200px;
}

/* Share Button */
.share-btn {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 0.8rem;
  background: transparent;
  color: var(--text-light);
  border: 1px solid var(--secondary-light);
  border-radius: 4px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  opacity: 0.7;
}

.share-btn:hover {
  opacity: 1;
  border-color: var(--secondary);
  color: var(--text);
  background: rgba(201, 169, 97, 0.08);
}

.share-icon {
  font-size: 0.85rem;
}

.share-text {
  letter-spacing: 0.03em;
}

/* Photo Background Toggle Button */
.photo-toggle-btn {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 0.8rem;
  background: transparent;
  color: var(--text-light);
  border: 1px solid var(--secondary-light);
  border-radius: 4px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  opacity: 0.7;
}

.photo-toggle-btn:hover {
  opacity: 1;
  border-color: var(--secondary);
  color: var(--text);
  background: rgba(201, 169, 97, 0.08);
}

.photo-toggle-btn.active {
  background: rgba(107, 15, 26, 0.08);
  color: var(--primary);
  border-color: var(--primary);
  opacity: 1;
}

.photo-toggle-icon {
  font-size: 0.85rem;
}

.photo-toggle-text {
  letter-spacing: 0.03em;
}

@media (max-width: 600px) {
  .quote-controls {
    gap: 0.25rem;
    margin-bottom: var(--space-xs);
  }

  .share-btn,
  .photo-toggle-btn {
    font-size: 0.7rem;
    padding: 0.35rem 0.6rem;
  }

  .share-text,
  .photo-toggle-text {
    display: none;
  }

  .share-icon,
  .photo-toggle-icon {
    font-size: 0.9rem;
  }
}

/* ============================================
   PREVIOUS QUOTES SECTION
   ============================================ */
.previous-quotes-section {
  padding: var(--space-lg) var(--space-lg) var(--space-xl);
  background: linear-gradient(180deg, var(--background) 0%, var(--background-alt) 100%);
  border-top: 1px solid var(--secondary-light);
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.header-line {
  width: 80px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--secondary), transparent);
}

.section-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-light);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.previous-quotes-scroll {
  overflow-x: auto;
  padding-bottom: var(--space-sm);
  -webkit-overflow-scrolling: touch;
}

.previous-quotes-scroll::-webkit-scrollbar {
  height: 6px;
}

.previous-quotes-scroll::-webkit-scrollbar-track {
  background: var(--background);
  border-radius: 3px;
}

.previous-quotes-scroll::-webkit-scrollbar-thumb {
  background: var(--secondary);
  border-radius: 3px;
}

.previous-quotes-container {
  display: flex;
  gap: var(--space-md);
  padding: var(--space-xs);
  min-width: min-content;
}

.previous-quotes-cards {
  display: flex;
  gap: var(--space-md);
}

.prev-quote-card {
  flex: 0 0 280px;
  background: var(--white);
  border: 1px solid var(--secondary-light);
  border-radius: 8px;
  padding: var(--space-md);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.prev-quote-card:hover {
  border-color: var(--secondary);
  box-shadow: 0 4px 15px var(--shadow);
  transform: translateY(-2px);
}

.prev-quote-card.active {
  border-color: var(--primary);
  background: linear-gradient(135deg, var(--white) 0%, rgba(107, 15, 26, 0.03) 100%);
}

.prev-quote-date {
  font-family: var(--font-author);
  font-size: 0.75rem;
  font-variant: small-caps;
  color: var(--secondary-dark);
  letter-spacing: 0.12em;
  margin-bottom: var(--space-sm);
}

.prev-quote-text {
  font-family: var(--font-author);
  font-size: 0.95rem;
  font-variant: small-caps;
  color: var(--text);
  line-height: 1.6;
  margin-bottom: var(--space-sm);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.prev-quote-author {
  font-family: var(--font-author);
  font-size: 0.85rem;
  font-variant: small-caps;
  font-weight: 500;
  color: var(--primary);
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  text-align: center;
  padding: var(--space-lg) var(--space-lg);
  background: var(--background-alt);
  border-top: 1px solid var(--secondary-light);
}

.footer-text {
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--text-light);
  letter-spacing: 0.08em;
}

.footer-year {
  font-weight: 600;
  color: var(--primary);
}

.footer-divider {
  margin: 0 var(--space-sm);
  color: var(--secondary);
}

.footer-nav {
  display: flex;
  justify-content: center;
  gap: var(--space-lg);
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--secondary-light);
}

.nav-link {
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--text-light);
  text-decoration: none;
  letter-spacing: 0.08em;
  padding: var(--space-xs) var(--space-md);
  border-bottom: 2px solid transparent;
  transition: var(--transition);
}

.nav-link:hover {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

/* ============================================
   LOADING & ANIMATIONS
   ============================================ */
.loading {
  opacity: 0.5;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 0.5;
  }

  50% {
    opacity: 0.8;
  }
}

.fade-in {
  animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

/* Tablet */
@media (max-width: 900px) {
  .mini-calendar {
    flex: 0 0 240px;
  }

  .main-content {
    max-width: 100%;
    padding: var(--space-lg) var(--space-md);
  }

  .quote-container,
  .contact-container {
    max-width: 100%;
    min-width: 0;
    width: 100%;
  }

  .scripture-card {
    max-width: 100%;
  }

  .quote-frame {
    padding: var(--space-lg) var(--space-md);
  }

  .quote-inner {
    padding: var(--space-md);
    padding-bottom: var(--space-lg);
  }
}

/* Mobile */
@media (max-width: 600px) {
  :root {
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-xxl: 3rem;
  }

  .header {
    padding: var(--space-md);
  }

  .site-title {
    font-size: 1.75rem;
  }

  .footer-nav {
    flex-direction: column;
    gap: var(--space-sm);
    padding-bottom: var(--space-md);
  }

  .nav-link {
    font-size: 0.85rem;
    padding: var(--space-xs) var(--space-sm);
  }

  .site-subtitle {
    font-size: 0.9rem;
  }

  .current-date {
    font-size: 0.8rem;
  }

  .mini-calendar {
    width: 100%;
    max-width: 200px;
  }

  .main-content {
    padding: var(--space-lg) var(--space-md);
    min-height: auto;
  }

  .scripture-card {
    padding: var(--space-md);
    margin-bottom: var(--space-md);
  }

  .scripture-text {
    font-size: 0.95rem;
  }

  .quote-frame,
  .contact-frame {
    padding: var(--space-md) var(--space-sm);
    border-width: 3px;
  }

  .quote-frame::before,
  .contact-frame::before {
    inset: 6px;
  }

  .quote-frame::after {
    inset: 10px;
  }

  .corner-ornament {
    width: 20px;
    height: 20px;
  }

  .quote-inner {
    padding: var(--space-md) var(--space-sm);
    padding-bottom: var(--space-lg);
  }

  .quote-mark {
    font-size: 3rem;
  }

  .quote-mark.opening {
    top: -0.5rem;
    left: -0.5rem;
  }

  .quote-mark.closing {
    bottom: 2.5rem;
    right: -0.5rem;
  }

  .quote-container {
    max-width: 100%;
    min-width: 0;
    width: 100%;
    padding: 0;
  }

  .quote-text {
    font-size: clamp(1.4rem, 6vw, 1.8rem);
    padding: var(--space-md) var(--space-xs);
    line-height: 1.6;
    letter-spacing: 0.02em;
  }

  .quote-divider {
    margin: var(--space-md) auto var(--space-sm);
  }

  .quote-divider::before,
  .quote-divider::after {
    width: 50px;
  }

  .side-ornament {
    display: none;
  }

  .corner-ornament {
    width: 25px;
    height: 25px;
  }

  .corner-ornament::before {
    font-size: 0.8rem;
  }

  .contact-inner {
    padding: var(--space-md);
  }

  .contact-title {
    font-size: 1.75rem;
  }

  .quote-author {
    font-size: 1rem;
    margin-top: var(--space-sm);
    padding: 0 var(--space-xs);
  }

  .prev-quote-card {
    flex: 0 0 240px;
    padding: var(--space-sm) var(--space-md);
  }

  .prev-quote-text {
    font-size: 0.9rem;
    -webkit-line-clamp: 2;
    line-clamp: 2;
  }

  .mini-calendar {
    flex: 0 0 240px;
  }
}

/* ============================================
   SHARE MODAL
   ============================================ */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
}

.modal-content {
  position: relative;
  background: var(--white);
  border-radius: 12px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.3);
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-share {
  max-width: 400px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--secondary-light);
}

.modal-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: var(--primary);
  font-weight: 600;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-light);
  cursor: pointer;
  padding: 0.5rem;
  line-height: 1;
  transition: var(--transition);
}

.modal-close:hover {
  color: var(--text);
}

.modal-body {
  padding: 1.5rem;
}

.share-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.share-option-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-lg);
  background: var(--background);
  border: 2px solid var(--secondary-light);
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-body);
}

.share-option-btn:hover {
  background: var(--secondary-light);
  border-color: var(--secondary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px var(--shadow);
}

.share-option-icon {
  font-size: 2rem;
}

.share-option-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.05em;
}

.share-message {
  padding: var(--space-md);
  border-radius: 6px;
  text-align: center;
  font-size: 0.9rem;
  display: none;
}

.share-message.success {
  display: block;
  background: rgba(44, 107, 63, 0.1);
  color: var(--accent);
  border: 1px solid var(--accent);
}

.share-message.error {
  display: block;
  background: rgba(192, 57, 43, 0.1);
  color: #C0392B;
  border: 1px solid #C0392B;
}

@media (max-width: 600px) {
  .share-options {
    grid-template-columns: 1fr;
  }

  .share-option-btn {
    flex-direction: row;
    justify-content: flex-start;
  }
}

/* ============================================
   CONTACT FORM
   ============================================ */
.contact-container {
  position: relative;
  width: 100%;
  max-width: 800px;
  min-width: 600px;
  text-align: center;
}

.contact-frame {
  position: relative;
  background: linear-gradient(135deg, var(--white) 0%, #FDFBF7 100%);
  border: 4px solid var(--primary);
  padding: var(--space-xl) var(--space-lg);
  box-shadow:
    0 8px 40px var(--shadow),
    inset 0 0 100px rgba(107, 15, 26, 0.03),
    inset 0 0 200px rgba(201, 169, 97, 0.05);
  width: 100%;
  overflow: hidden;
}

.contact-frame::before {
  content: '';
  position: absolute;
  inset: 12px;
  border: 2px solid var(--secondary);
  pointer-events: none;
  box-shadow: inset 0 0 20px rgba(201, 169, 97, 0.1);
}

.contact-frame::after {
  content: '';
  position: absolute;
  inset: 20px;
  border: 1px solid rgba(201, 169, 97, 0.3);
  pointer-events: none;
}

.contact-inner {
  position: relative;
  padding: var(--space-lg);
  background:
    radial-gradient(circle at 20% 30%, rgba(201, 169, 97, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(107, 15, 26, 0.02) 0%, transparent 50%);
}

.contact-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.08em;
  margin-bottom: var(--space-sm);
  text-shadow: 1px 1px 2px var(--shadow);
}

.contact-subtitle {
  font-family: var(--font-body);
  font-size: 1rem;
  font-style: italic;
  color: var(--text-light);
  letter-spacing: 0.1em;
  margin-bottom: var(--space-xl);
}

.contact-form {
  text-align: left;
  max-width: 600px;
  margin: 0 auto;
}

.contact-form .form-group {
  margin-bottom: var(--space-lg);
}

.contact-form label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.05em;
  margin-bottom: var(--space-sm);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: var(--space-md);
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text);
  background: var(--white);
  border: 2px solid var(--secondary-light);
  border-radius: 6px;
  transition: var(--transition);
  box-sizing: border-box;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(107, 15, 26, 0.1);
}

.contact-form textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.6;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--inactive);
  font-style: italic;
}

/* Honeypot field - hidden from users */
.honeypot-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

/* CAPTCHA styling */
.captcha-group {
  background: var(--background);
  padding: var(--space-md);
  border-radius: 6px;
  border: 1px solid var(--secondary-light);
}

.captcha-container {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-top: var(--space-sm);
}

.captcha-question {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--primary);
  min-width: 100px;
  text-align: center;
}

.captcha-container input {
  flex: 1;
  max-width: 120px;
}

.btn-refresh {
  background: var(--secondary-light);
  border: 1px solid var(--secondary);
  color: var(--primary);
  padding: var(--space-sm) var(--space-md);
  border-radius: 6px;
  cursor: pointer;
  font-size: 1.2rem;
  transition: var(--transition);
  line-height: 1;
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-refresh:hover {
  background: var(--secondary);
  border-color: var(--secondary-dark);
  transform: rotate(90deg);
}

.form-actions {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  margin-top: var(--space-xl);
}

.btn {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: var(--space-md) var(--space-lg);
  border: 2px solid;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
  box-shadow: 0 2px 8px var(--shadow);
}

.btn-primary:hover:not(:disabled) {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px var(--shadow);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-outline:hover:not(:disabled) {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px var(--shadow);
}

.contact-message {
  padding: var(--space-md);
  border-radius: 6px;
  text-align: center;
  font-size: 0.95rem;
  font-family: var(--font-body);
  margin-bottom: var(--space-md);
  display: none;
}

.contact-message.success {
  display: block;
  background: rgba(44, 107, 63, 0.1);
  color: var(--accent);
  border: 1px solid var(--accent);
}

.contact-message.error {
  display: block;
  background: rgba(192, 57, 43, 0.1);
  color: #C0392B;
  border: 1px solid #C0392B;
}

@media (max-width: 600px) {
  .contact-container {
    min-width: auto;
  }

  .contact-form {
    max-width: 100%;
  }

  .captcha-container {
    flex-wrap: wrap;
  }

  .captcha-question {
    width: 100%;
    margin-bottom: var(--space-xs);
  }

  .captcha-container input {
    flex: 1;
    max-width: none;
  }

  .form-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }
}

/* Print Styles */
@media print {

  .mini-calendar,
  .previous-quotes-section,
  .footer,
  .share-btn {
    display: none;
  }

  .main-content {
    padding-right: var(--space-lg);
  }

  .quote-container {
    max-width: 100%;
  }

  .quote-frame {
    box-shadow: none;
    border: 2px solid #333;
  }
}