/* Page-owned styles for Unsere Geschichte */

/* Hero section */
.hero-story {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background-color: var(--color-ink);
}

.hero-story__bg {
  position: absolute;
  inset: 0;
  background-image: url('/public/media/festquorin-hero-interior.webp');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  z-index: 0;
}

.hero-story__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(23, 19, 17, 0.95) 0%, rgba(23, 19, 17, 0.6) 40%, rgba(23, 19, 17, 0.2) 100%);
  z-index: 1;
}

.hero-story__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding: var(--space-xxxl) var(--container-padding-mobile);
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-xl);
}

.hero-story__text {
  flex: 1 1 600px;
  max-width: 600px;
  min-width: 0;
}

.hero-story__text h1 {
  font-size: var(--text-display);
  line-height: var(--leading-display);
  margin-block-end: var(--space-lg);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}

.hero-story__lead {
  font-size: var(--text-body);
  line-height: var(--leading-body);
  max-width: 55ch;
  color: var(--color-champagne);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
}

.hero-story__cards {
  flex: 0 0 280px;
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  min-width: 0;
}

.phase-card {
  background-color: rgba(59, 38, 54, 0.85);
  border: 1px solid var(--border-color-gold);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(4px);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  opacity: 0;
  transform: translateY(20px);
}

.phase-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.phase-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
}

.phase-card__icon {
  display: block;
  font-size: 1.5rem;
  color: var(--color-gold);
  margin-block-end: var(--space-sm);
}

.phase-card__title {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  margin-block-end: var(--space-xs);
}

.phase-card__text {
  font-size: var(--text-small);
  line-height: var(--leading-small);
  color: rgba(var(--color-champagne-rgb), 0.85);
  margin-block-end: 0;
}

/* Origin section */
.story-origin {
  background-color: var(--color-velvet);
}

.story-origin__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: var(--space-xxl);
  align-items: center;
}

.story-origin__text {
  min-width: 0;
}

.story-origin__text h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-lg);
}

.story-origin__text p {
  max-width: 60ch;
  margin-block-end: var(--space-md);
}

.story-origin__figure {
  margin: 0;
  min-width: 0;
}

.story-origin__figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-deep);
  display: block;
}

/* Philosophy section */
.philosophy {
  background-color: var(--color-velvet);
}

.philosophy__intro {
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
  margin-block-end: var(--space-xxl);
}

.philosophy__intro h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-md);
}

.philosophy__intro p {
  max-width: 60ch;
  margin-inline: auto;
}

.philosophy__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-xl);
}

.philosophy-card {
  background-color: var(--color-velvet);
  border: 1px solid var(--border-color-gold);
  border-radius: var(--radius-md);
  padding: var(--space-xl);
  text-align: center;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.philosophy-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-card-hover);
}

.philosophy-card__icon {
  font-size: 2.5rem;
  line-height: 1;
  margin-block-end: var(--space-xs);
}

.philosophy-card__title {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  margin-block-end: 0;
}

.philosophy-card__text {
  font-size: var(--text-body);
  line-height: var(--leading-body);
  max-width: 35ch;
  margin-block-end: 0;
}

/* Team section */
.team {
  background-color: var(--color-ink);
}

.team__intro {
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
  margin-block-end: var(--space-xxl);
}

.team__intro h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-md);
}

.team__intro p {
  max-width: 60ch;
  margin-inline: auto;
}

.team__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-xl);
}

.team-member {
  text-align: center;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
}

.team-member__figure {
  margin: 0;
  width: 100%;
  max-width: 300px;
}

.team-member__figure img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid var(--border-color-gold);
  box-shadow: var(--shadow-soft);
  display: block;
}

.team-member__role {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  margin-block-end: 0;
}

.team-member__text {
  font-size: var(--text-body);
  line-height: var(--leading-body);
  max-width: 40ch;
  margin-block-end: 0;
}

/* Spaces section */
.spaces {
  background-color: var(--color-velvet);
}

.spaces__intro {
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
  margin-block-end: var(--space-xxl);
}

.spaces__intro h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-md);
}

.spaces__intro p {
  max-width: 60ch;
  margin-inline: auto;
}

.spaces__hero {
  margin: 0 0 var(--space-xxl);
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-deep);
}

.spaces__hero img {
  width: 100%;
  height: 500px;
  object-fit: cover;
  display: block;
}

.spaces__hero figcaption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-lg);
  background: linear-gradient(to top, rgba(23, 19, 17, 0.9), transparent);
  color: var(--color-champagne);
  font-size: var(--text-small);
  line-height: var(--leading-small);
  margin: 0;
}

.spaces__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-xl);
}

.space-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.space-card__figure {
  margin: 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}

.space-card__figure img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
  transition: transform var(--transition-base);
}

.space-card:hover .space-card__figure img {
  transform: scale(1.03);
}

.space-card__title {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  margin-block-end: 0;
}

.space-card__text {
  font-size: var(--text-body);
  line-height: var(--leading-body);
  margin-block-end: 0;
}

/* Evening flow timeline */
.evening-flow {
  background-color: var(--color-ink);
}

.evening-flow__intro {
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
  margin-block-end: var(--space-xxl);
}

.evening-flow__intro h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-md);
}

.evening-flow__intro p {
  max-width: 60ch;
  margin-inline: auto;
}

.timeline {
  list-style: none;
  padding: 0;
  margin: 0;
  position: relative;
  max-width: 900px;
  margin-inline: auto;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  background-color: var(--border-color-gold);
  transform: translateX(-50%);
}

.timeline__item {
  position: relative;
  width: 50%;
  padding: var(--space-lg) var(--space-xl);
  min-width: 0;
}

.timeline__item:nth-child(odd) {
  left: 0;
  text-align: right;
}

.timeline__item:nth-child(even) {
  left: 50%;
  text-align: left;
}

.timeline__marker {
  position: absolute;
  top: 50%;
  width: 14px;
  height: 14px;
  background-color: var(--color-gold);
  border-radius: 50%;
  border: 2px solid var(--color-ink);
  box-shadow: 0 0 0 2px var(--color-gold);
  transform: translateY(-50%);
}

.timeline__item:nth-child(odd) .timeline__marker {
  right: -7px;
}

.timeline__item:nth-child(even) .timeline__marker {
  left: -7px;
}

.timeline__content {
  background-color: var(--color-velvet);
  border: 1px solid var(--border-color-gold);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  box-shadow: var(--shadow-soft);
  display: inline-block;
  max-width: 100%;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity var(--transition-base), transform var(--transition-base);
}

.timeline__item.is-visible .timeline__content {
  opacity: 1;
  transform: translateY(0);
}

.timeline__title {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  margin-block-end: var(--space-xs);
}

.timeline__text {
  font-size: var(--text-body);
  line-height: var(--leading-body);
  max-width: 50ch;
  margin-block-end: 0;
}

.timeline__item:nth-child(odd) .timeline__text {
  margin-inline-start: auto;
}

/* Values section */
.values {
  background-color: var(--color-velvet);
}

.values__intro {
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
  margin-block-end: var(--space-xxl);
}

.values__intro h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-md);
}

.values__intro p {
  max-width: 60ch;
  margin-inline: auto;
}

.values__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-xl);
  max-width: 900px;
  margin-inline: auto;
}

.values__column {
  min-width: 0;
}

.values__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.values__item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  font-size: var(--text-body);
  line-height: var(--leading-body);
}

.values__check {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--color-gold);
  color: var(--color-ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}

/* Reservation invite */
.reservation-invite {
  background-color: var(--color-ink);
}

.reservation-invite__inner {
  max-width: 600px;
  margin-inline: auto;
  text-align: center;
  padding: var(--space-xxl);
  border: 1px solid var(--border-color-gold);
  border-radius: var(--radius-lg);
  background-color: var(--color-velvet);
  box-shadow: var(--shadow-deep);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-lg);
}

.reservation-invite__inner h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: 0;
}

.reservation-invite__text {
  max-width: 50ch;
  margin-block-end: 0;
}

.reservation-invite__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-md);
  width: 100%;
}

.reservation-invite__actions .btn {
  min-width: 200px;
}

.reservation-invite__contact {
  font-size: var(--text-small);
  line-height: var(--leading-small);
  color: var(--color-copper);
  margin-block-end: 0;
}

.reservation-invite__contact a {
  color: var(--color-gold);
}

.reservation-invite__contact a:hover {
  color: var(--color-copper);
}

/* Responsive adjustments */
@media (max-width: 63.999rem) {
  .hero-story__content {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-xl);
  }

  .hero-story__cards {
    flex: 1 1 auto;
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
  }

  .phase-card {
    flex: 1 1 240px;
  }

  .story-origin__grid {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
  }

  .story-origin__figure {
    order: -1;
  }

  .philosophy__grid,
  .team__grid,
  .spaces__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .timeline::before {
    left: 20px;
  }

  .timeline__item,
  .timeline__item:nth-child(odd),
  .timeline__item:nth-child(even) {
    width: 100%;
    left: 0;
    text-align: left;
    padding-inline-start: 50px;
    padding-inline-end: 0;
  }

  .timeline__item:nth-child(odd) .timeline__marker,
  .timeline__item:nth-child(even) .timeline__marker {
    left: 13px;
    right: auto;
  }

  .timeline__item:nth-child(odd) .timeline__text {
    margin-inline-start: 0;
  }

  .values__grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
}

@media (max-width: 47.999rem) {
  .hero-story {
    min-height: 100vh;
    min-height: 100dvh;
  }

  .hero-story__bg {
    background-attachment: scroll;
  }

  .hero-story__content {
    padding: var(--space-xxl) var(--container-padding-mobile);
    gap: var(--space-lg);
  }

  .hero-story__text h1 {
    font-size: var(--text-h1);
    line-height: var(--leading-h1);
  }

  .hero-story__lead {
    font-size: var(--text-body);
  }

  .hero-story__cards {
    flex-direction: column;
  }

  .phase-card {
    flex: 1 1 auto;
  }

  .philosophy__grid,
  .team__grid,
  .spaces__grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .spaces__hero img {
    height: 300px;
  }

  .reservation-invite__inner {
    padding: var(--space-xl);
  }

  .reservation-invite__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .reservation-invite__actions .btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-story__bg {
    background-attachment: scroll;
  }

  .phase-card,
  .timeline__content {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
