/* ==========================================================================
   WHITE BEARD COFFEE & ROASTERY
   Coffee & Beans — Responsive
   File: /assets/css/responsive/coffee-and-beans-responsive.css
   ========================================================================== */


/* ==========================================================================
   LARGE DESKTOP
   <= 1199px
   ========================================================================== */

@media (max-width: 1199px) {
  .coffee-hero__title {
    font-size: clamp(4.5rem, 7vw, 7rem);
  }

  .coffee-hero__content {
    width: min(100%, 61rem);
  }

  .coffee-catalog__header,
  .coffee-direction__header {
    gap: clamp(2.5rem, 5vw, 5rem);
  }

  .coffee-catalog__toolbar {
    grid-template-columns: minmax(0, 1fr);
  }

  .coffee-catalog__controls {
    display: grid;

    grid-template-columns:
      minmax(14rem, 1fr)
      minmax(11rem, 0.4fr);

    width: min(100%, 40rem);
  }

  .coffee-search__control,
  .coffee-sort__select {
    width: 100%;
  }

  .coffee-products,
  [data-coffee-products] {
    column-gap: 1.5rem;
  }

  .coffee-card__title {
    font-size: clamp(1.65rem, 2.1vw, 2.25rem);
  }

  .coffee-consultation__grid {
    grid-template-columns:
      minmax(0, 1fr)
      minmax(25rem, 0.9fr);
  }

  .product-modal {
    width: min(96vw, 82rem);
  }

  .product-modal__layout {
    grid-template-columns:
      minmax(0, 1fr)
      minmax(25rem, 0.95fr);
  }

  .product-modal__information {
    padding:
      4.5rem
      clamp(2.25rem, 4vw, 4rem)
      3.5rem;
  }
}


/* ==========================================================================
   TABLET
   <= 991px
   ========================================================================== */

@media (max-width: 991px) {
  /* Hero */

  .coffee-hero {
    min-height: max(43rem, 82svh);
  }

  .coffee-hero__inner {
    min-height:
      calc(
        max(43rem, 82svh) -
        var(--header-height, 88px)
      );

    padding-top: 7rem;
    padding-bottom: 4.5rem;
  }

  .coffee-hero__content {
    width: min(100%, 48rem);
  }

  .coffee-hero__title {
    max-width: 10ch;

    font-size: clamp(4.25rem, 10vw, 6.5rem);
  }

  .coffee-hero__bottom {
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
  }

  .coffee-hero__copy {
    max-width: 39rem;
  }

  .coffee-hero__meta {
    width: min(100%, 28rem);
  }

  .coffee-hero__scroll {
    display: none;
  }


  /* Catalog header */

  .coffee-catalog__header {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 1.75rem;
  }

  .coffee-catalog__title {
    max-width: 11ch;
  }

  .coffee-catalog__description {
    max-width: 39rem;
  }


  /* Toolbar */

  .coffee-catalog__toolbar {
    gap: 1.75rem;
  }

  .coffee-catalog__controls {
    width: 100%;
  }


  /* Product grid */

  .coffee-products,
  [data-coffee-products] {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));

    gap:
      4rem
      clamp(1.25rem, 3vw, 2rem);
  }

  .coffee-card__title {
    font-size: clamp(1.8rem, 3.4vw, 2.4rem);
  }


  /* Coffee direction */

  .coffee-direction__header {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 1.75rem;
  }

  .coffee-direction__intro {
    max-width: 39rem;
  }

  .coffee-direction__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .coffee-direction__item {
    display: grid;

    grid-template-columns:
      4rem
      minmax(10rem, 0.35fr)
      minmax(0, 1fr);

    min-height: 0;

    align-items: start;
    gap: 1.5rem;

    padding-block: 2.25rem;

    border-right: 0;
    border-bottom: 1px solid rgba(25, 23, 20, 0.16);
  }

  .coffee-direction__item:last-child {
    border-bottom: 0;
  }

  .coffee-direction__number {
    margin: 0;
  }

  .coffee-direction__item-copy {
    margin-top: 0;
  }

  .coffee-direction__item-note {
    grid-column: 3;
    justify-self: start;
  }


  /* Consultation */

  .coffee-consultation__grid {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
  }

  .coffee-consultation__media {
    min-height: 34rem;
  }

  .coffee-consultation__content {
    padding:
      clamp(4.5rem, 8vw, 7rem)
      var(--container-padding, 2rem);
  }

  .coffee-consultation__title {
    max-width: 12ch;
  }


  /* Product modal */

  .product-modal {
    width: min(94vw, 48rem);
    max-height: 92svh;
  }

  .product-modal__body {
    max-height: 92svh;
  }

  .product-modal__layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .product-modal__gallery {
    padding: clamp(1.25rem, 4vw, 2rem);
  }

  .product-modal__stage {
    aspect-ratio: 16 / 11;
  }

  .product-modal__information {
    padding:
      3.5rem
      clamp(2rem, 6vw, 4rem)
      3.5rem;
  }

  .product-modal__title {
    max-width: 18ch;
  }
}


/* ==========================================================================
   MOBILE
   <= 767px
   ========================================================================== */

@media (max-width: 767px) {
  /* Hero */

  .coffee-hero {
    min-height: max(40rem, 82svh);
  }

  .coffee-hero__picture {
    inset: -2%;

    width: 104%;
    height: 104%;
  }

  .coffee-hero__overlay {
    background:
      linear-gradient(
        180deg,
        rgba(25, 23, 20, 0.25) 0%,
        rgba(25, 23, 20, 0.4) 32%,
        rgba(25, 23, 20, 0.94) 100%
      );
  }

  .coffee-hero__inner {
    min-height:
      calc(
        max(40rem, 82svh) -
        var(--header-height, 88px)
      );

    justify-content: flex-end;

    padding-top: 6rem;
    padding-bottom: 3.5rem;
  }

  .coffee-hero__eyebrow {
    font-size: 0.6875rem;
  }

  .coffee-hero__title {
    max-width: 9ch;

    font-size: clamp(3.75rem, 15vw, 5.75rem);
    line-height: 0.9;
  }

  .coffee-hero__bottom {
    margin-top: 2rem;
    padding-top: 1.5rem;
  }

  .coffee-hero__copy {
    font-size: 1rem;
    line-height: 1.7;
  }

  .coffee-hero__meta {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));

    width: 100%;
  }


  /* Main section spacing */

  .coffee-catalog,
  .coffee-direction {
    padding-top: 5.5rem;
    padding-bottom: 5.5rem;
  }


  /* Catalog header */

  .coffee-catalog__header {
    margin-bottom: 2.5rem;
  }

  .coffee-catalog__title {
    font-size: clamp(3rem, 13vw, 4.5rem);
  }

  .coffee-catalog__description {
    font-size: 1rem;
    line-height: 1.7;
  }


  /* Toolbar */

  .coffee-catalog__toolbar {
    margin-right:
      calc(var(--container-padding, 1.25rem) * -1);
    margin-left:
      calc(var(--container-padding, 1.25rem) * -1);

    padding-right: var(--container-padding, 1.25rem);
    padding-left: var(--container-padding, 1.25rem);
  }

  .coffee-catalog__filters {
    min-width: 0;
    overflow: hidden;
  }

  .coffee-filters,
  [data-coffee-filters] {
    flex-wrap: nowrap;

    margin-right:
      calc(var(--container-padding, 1.25rem) * -1);
    padding-right: var(--container-padding, 1.25rem);
    padding-bottom: 0.5rem;

    overflow-x: auto;
    overflow-y: hidden;

    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }

  .coffee-filters::-webkit-scrollbar,
  [data-coffee-filters]::-webkit-scrollbar {
    display: none;
  }

  .coffee-filter {
    flex: 0 0 auto;
    scroll-snap-align: start;
  }

  .coffee-catalog__controls {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
  }

  .coffee-search__control,
  .coffee-sort__select {
    width: 100%;
    min-width: 0;
  }


  /* Result information */

  .coffee-catalog__result {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }


  /* Product grid */

  .coffee-products,
  [data-coffee-products] {
    grid-template-columns: minmax(0, 1fr);
    gap: 4.5rem;
  }

  .coffee-card {
    width: min(100%, 36rem);
    margin-inline: auto;
  }

  .coffee-card__content {
    padding-top: 1.25rem;
  }

  .coffee-card__title {
    font-size: clamp(2rem, 8vw, 2.75rem);
  }

  .coffee-card__description {
    max-width: none;

    font-size: 0.9375rem;

    -webkit-line-clamp: 4;
  }

  .coffee-card__meta {
    gap: 0.75rem;
  }


  /* Empty state */

  .coffee-catalog__empty,
  [data-coffee-empty] {
    padding:
      3.5rem
      var(--container-padding, 1.25rem);
  }


  /* Coffee direction */

  .coffee-direction__title {
    font-size: clamp(2.8rem, 12vw, 4.25rem);
  }

  .coffee-direction__grid {
    border-bottom: 0;
  }

  .coffee-direction__item {
    display: block;

    padding:
      2.5rem
      0;
  }

  .coffee-direction__number {
    margin-bottom: 2rem;
  }

  .coffee-direction__item-title {
    font-size: clamp(2rem, 8vw, 2.75rem);
  }

  .coffee-direction__item-copy {
    margin-top: 1rem;
  }

  .coffee-direction__item-note {
    margin-top: 1.5rem;
  }


  /* Consultation */

  .coffee-consultation__media {
    min-height: 28rem;
  }

  .coffee-consultation__picture {
    inset: -2%;

    width: 104%;
    height: 104%;
  }

  .coffee-consultation__content {
    padding-top: 5rem;
    padding-bottom: 5rem;
  }

  .coffee-consultation__title {
    font-size: clamp(3rem, 13vw, 4.75rem);
  }

  .coffee-consultation__copy {
    font-size: 1rem;
  }


  /* Product modal */

  .product-modal {
    width: 100vw;
    max-width: none;
    height: 100dvh;
    max-height: 100dvh;

    margin: 0;

    border-radius: 0;
  }

  .product-modal__body {
    height: 100dvh;
    max-height: 100dvh;
  }

  .product-modal__layout {
    min-height: 100%;
  }

  .product-modal__close {
    position: fixed;
    top: calc(1rem + env(safe-area-inset-top));
    right: 1rem;
  }

  .product-modal__gallery {
    padding:
      calc(1rem + env(safe-area-inset-top))
      var(--container-padding, 1.25rem)
      1.5rem;
  }

  .product-modal__stage {
    aspect-ratio: 1 / 1;
  }

  .product-modal__thumbnails {
    grid-auto-columns: 4.5rem;
  }

  .product-modal__thumbnail {
    width: 4.5rem;
  }

  .product-modal__information {
    padding:
      3.5rem
      var(--container-padding, 1.25rem)
      calc(4rem + env(safe-area-inset-bottom));
  }

  .product-modal__top {
    padding-right: 3.5rem;
  }

  .product-modal__title {
    font-size: clamp(2.5rem, 11vw, 4rem);
  }

  .product-modal__actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }

  .product-modal__action {
    width: 100%;
  }
}


/* ==========================================================================
   SMALL MOBILE
   <= 479px
   ========================================================================== */

@media (max-width: 479px) {
  /* Hero */

  .coffee-hero {
    min-height: max(38rem, 80svh);
  }

  .coffee-hero__inner {
    min-height:
      calc(
        max(38rem, 80svh) -
        var(--header-height, 88px)
      );

    padding-bottom: 3rem;
  }

  .coffee-hero__eyebrow::before {
    width: 1.5rem;
    flex-basis: 1.5rem;
  }

  .coffee-hero__title {
    font-size: clamp(3.35rem, 15vw, 4.5rem);
  }

  .coffee-hero__meta {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.875rem;
  }

  .coffee-hero__meta-item {
    padding-top: 0.875rem;

    border-top: 1px solid rgba(255, 255, 255, 0.16);
  }


  /* Filters */

  .coffee-filter {
    min-height: 2.65rem;
    padding-right: 0.9rem;
    padding-left: 0.9rem;
  }


  /* Product cards */

  .coffee-card__status {
    top: 0.75rem;
    left: 0.75rem;
  }

  .coffee-card__notes {
    gap: 0.4rem;
  }

  .coffee-card__meta {
    grid-template-columns: minmax(0, 1fr);
  }

  .coffee-card__meta-group + .coffee-card__meta-group {
    padding-top: 0.875rem;

    border-top: 1px solid rgba(25, 23, 20, 0.1);
  }


  /* Consultation actions */

  .coffee-consultation__actions {
    flex-direction: column;
    align-items: stretch;

    width: min(100%, 22rem);
  }

  .coffee-consultation__actions .wb-button {
    width: 100%;
    justify-content: center;
  }


  /* Product modal */

  .product-modal__gallery {
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .product-modal__information {
    padding-right: 1.25rem;
    padding-left: 1.25rem;
  }

  .product-modal__top {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.65rem;

    padding-right: 3rem;
  }

  .product-modal__details {
    grid-template-columns: minmax(0, 1fr);
  }

  .product-modal__detail,
  .product-modal__detail:nth-child(even) {
    padding-right: 0;
    padding-left: 0;

    border-left: 0;
  }

  .product-modal__thumbnail {
    width: 4rem;
  }

  .product-modal__thumbnails {
    grid-auto-columns: 4rem;
  }

  .product-modal__tags {
    gap: 0.4rem;
  }

  .product-modal__tag {
    font-size: 0.6875rem;
  }
}


/* ==========================================================================
   SHORT LANDSCAPE DEVICE
   ========================================================================== */

@media (max-height: 620px) and (orientation: landscape) {
  .coffee-hero {
    min-height: 42rem;
  }

  .coffee-hero__inner {
    min-height:
      calc(
        42rem -
        var(--header-height, 88px)
      );

    padding-top: 5rem;
    padding-bottom: 3rem;
  }

  .coffee-hero__title {
    font-size: clamp(3.75rem, 9vw, 5.5rem);
  }

  .coffee-hero__bottom {
    margin-top: 1.75rem;
  }

  .coffee-consultation__grid {
    min-height: 36rem;
  }

  .product-modal {
    max-height: 96svh;
  }

  .product-modal__body {
    max-height: 96svh;
  }
}


/* ==========================================================================
   REDUCED MOTION
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .coffee-hero__picture,
  .coffee-consultation__picture {
    transform: none !important;
  }

  .coffee-filters,
  [data-coffee-filters],
  .product-modal__thumbnails {
    scroll-behavior: auto;
  }
}


/* ==========================================================================
   PRINT
   ========================================================================== */

@media print {
  .coffee-catalog__toolbar,
  .coffee-catalog__clear,
  .coffee-card__open,
  .coffee-consultation__actions,
  .product-modal {
    display: none !important;
  }

  .coffee-hero {
    min-height: auto;
    padding: 3rem 0;

    color: #000000;
    background: #ffffff;
  }

  .coffee-hero__media,
  .coffee-hero__overlay,
  .coffee-hero__grain,
  .coffee-hero__scroll {
    display: none;
  }

  .coffee-hero__inner {
    display: block;
    min-height: auto;

    padding-top: 0;
    padding-bottom: 0;
  }

  .coffee-hero__title,
  .coffee-hero__eyebrow,
  .coffee-hero__copy,
  .coffee-hero__meta-label,
  .coffee-hero__meta-value {
    color: #000000;
  }

  .coffee-hero__bottom {
    display: block;

    border-color: #bbbbbb;
  }

  .coffee-hero__meta {
    margin-top: 1.5rem;
  }

  .coffee-catalog,
  .coffee-direction,
  .coffee-consultation {
    padding-top: 3rem;
    padding-bottom: 3rem;

    color: #000000;
    background: #ffffff;
  }

  .coffee-products,
  [data-coffee-products] {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));

    gap: 2rem;
  }

  .coffee-card {
    break-inside: avoid;
  }

  .coffee-direction__grid {
    display: block;
  }

  .coffee-direction__item {
    min-height: 0;
    padding: 1.5rem 0;

    border-right: 0;
    border-bottom: 1px solid #bbbbbb;
  }

  .coffee-direction__number {
    margin-bottom: 1rem;
  }

  .coffee-consultation__grid {
    display: block;
    min-height: auto;
  }

  .coffee-consultation__media {
    display: none;
  }

  .coffee-consultation__content {
    padding: 0;
  }

  .coffee-consultation__title,
  .coffee-consultation__eyebrow,
  .coffee-consultation__copy {
    color: #000000;
  }
}