/********** Normalize-accessible **********/

/*** Box sizing universel ***/
*,
*::before,
*::after {
  box-sizing: border-box;
}

/*** Reset base ***/
html {
  font-size: 100%;  /* For rem (preference user) */
  scroll-padding-top: 120px;  /* Compensation for header padding */
  margin-top: 100px;
}

body {
  margin: 0;
}

/*** Media and graphic elements ***/
img {
  display: block;
  max-width: 100%;
}

/*** Forms ***/
button, input, textarea {
  font: inherit;
}

/*** Lists ***/
ul[role='list'],
ol[role='list'] {
  list-style: none;
  padding: 0;
  margin: 0
}

/*** Focus visibility for keyboard users ***/
:focus-visible {
  outline: 2px solid var(--color-focus-outline);
  outline-offset: 2px;
}

/*** User motion preferences ***/
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ----------------------------------------------------------------------------------------- */

/********** Tokens **********/

/*** Fonts declaration ***/
@font-face {
  font-family: 'Alatsi';
  src: url('../assets/fonts/alatsi/Alatsi-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Source_sans_3';
  src: url('../assets/fonts/source_sans_3/SourceSans3-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/*** Global ***/
:root {
  /* Typography */
  --font-family-display: 'Alatsi', serif, system-ui;
  --font-family-body: 'Source_sans_3', sans-serif, system-ui;

  --font-size-h1: clamp(3rem, 6.5vw, 4rem);  /* 64px -> 48px mobile */
  --font-size-h1-subtitle: 1.5rem;  /* 24px */
  --font-size-h2: 2rem;  /* 32px */
  --font-size-h3: 1.75rem;  /* 28px */
  --font-size-h4: 1.5rem;  /* 24px */
  --font-size-high-text: 1.375rem;  /* 22px */
  --font-size-text: 1.125rem;  /* 18px */

  --line-height-h1: 1.1;
  --line-height-h1-subtitle: 1.6;
  --line-height-h2: 1.2;
  --line-height-h3: 1.25;
  --line-height-h4: 1.3;
  --line-height-high-text: 1.4;
  --line-height-text: 1.35;

  /* Spacing scale */
  --space-container-y: clamp(1.875rem, 3vw, 3.125rem);  /* top & bottom : 50px → 30px mobile */
  --space-container-x: clamp(1.875rem, 7vw, 6.25rem);  /* left & right : 100px → 30px mobile */

  /* Radius */
  --radius-10: 10px;
  --radius-50: 50px;

  /* Shadows */
  --shadow-strong: 0 4px 4px rgba(0, 0, 0, 1);
  --shadow-light: 0 4px 4px rgba(0, 0, 0, 0.25);
  --shadow-subtle: 3px 3px 2px rgba(0, 0, 0, 0.25);

  /* Z-index scale */
  --z-base: 1;
  --z-header: 10;

  /* Color palette */
  --black: 47, 47, 47;  /* In rbg for shadows */
  --red: #B22222;
  --green: #3B7A57;
  --white: #FFFFFF;
  --orange: #F77A13;  /* Only for Focus outline */
  --warning-red: #FF0000;  /* Only for Error messages */
  --success-green: #28A745;  /* Only for Validation messages */
}

/*** Theme ***/
body.theme {
  --color-bg-content: var(--white);
  --color-bg-header: var(--white);
  --color-bg-footer: var(--white);

  --color-h1-content: var(--white);
  --color-h2-content: var(--black);
  --color-h3-content: var(--black);
  --color-h4-content: var(--black);
  --color-high-text-content: var(--black);
  --color-text-content: var(--black);

  --color-btn-primary-bg: var(--green);
  --color-btn-primary-text: var(--white);
  --color-btn-primary-bg-hover: var(--red);
  --color-btn-primary-text-hover: var(--white);
  --color-btn-secondary-bg: var(--white);
  --color-btn-secondary-text: var(--green);
  --color-btn-secondary-bg-hover: var(--green);
  --color-btn-secondary-text-hover: var(--white);
  --color-btn-third-bg: var(--white);
  --color-btn-third-text: var(--black);
  --color-btn-third-bg-hover: var(--red);
  --color-btn-third-text-hover: var(--white);

  --color-underline: var(--red);

  --color-border-classic: var(--black);
  --color-border-decorative-1: var(--green);
  --color-border-decorative-2: var(--red);

  --color-error: var(--warning-red);
  --color-validate: var(--success-green);

  --color-focus-outline: var(--orange);
}

/* ----------------------------------------------------------------------------------------- */

/********** Base **********/

/*** Document body ***/
body {
  font-family: var(--font-family-body);
  font-size: var(--font-size-text);
  line-height: var(--line-height-text);
  color: var(--color-text-content, #000);
  background-color: var(--color-bg-content, #fff);
}

/*** Headings, Paragraphs et Bullets ***/
h1, h2, h3, h4 { font-family: var(--font-family-display) }

h1 {
  font-size: var(--font-size-h1);
  line-height: var(--line-height-h1);
  letter-spacing: 2px;
  word-spacing: 4px;
}

h2 {
  font-size: var(--font-size-h2);
  line-height: var(--line-height-h2);
}

h3 {
  font-size: var(--font-size-h3);
  line-height: var(--line-height-h3);
}

h4 {
  font-size: var(--font-size-h4);
  line-height: var(--line-height-h4);
}

h1, h2, h3, h4, p, ul, ol { margin-block: 0; }

/*** Buttons ***/
button {  /* Reset before design */
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
}

/*** Links ***/
a {
  color: inherit;
  text-decoration: none;
}

/*** Placeholders ***/
input::placeholder,
textarea::placeholder {
  font-style: italic;
}

/* ----------------------------------------------------------------------------------------- */

/********** Utilities **********/

.heading-subtitle {
  font-family: var(--font-family-display);
  font-size: var(--font-size-h1-subtitle);
  line-height: var(--line-height-h1-subtitle);
}

.high-text {
  font-family: var(--font-family-display);
  font-size: var(--font-size-high-text);
  line-height: var(--line-height-high-text);
}

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

.error-message {
  color: var(--color-error);
  font-size: 1rem;
}

.error-message:empty {
  display: none;  /* Hide empty message zone */
}

span.required-field {
  color: var(--warning-red);
}

span.validated-field {
  color: var(--success-green);
}

/* ----------------------------------------------------------------------------------------- */

/********** Global-layout **********/

/*** General containers ***/
.layout-section {
  max-width: 1440px;
  margin-inline: auto;
  padding: var(--space-container-y) var(--space-container-x);
  display: flex;
  flex-direction: column;
}

/* ----------------------------------------------------------------------------------------- */

/********** Content **********/
.content h1,
.content .heading-subtitle {
  color: var(--color-h1-content);
  text-shadow:
    /* Outline */
    -1px -1px 0 rgba(var(--black), 0.2),
     1px -1px 0 rgba(var(--black), 0.2),
    -1px  1px 0 rgba(var(--black), 0.2),
     1px  1px 0 rgba(var(--black), 0.2),
    /* Cast shadow */
     var(--shadow-strong);
}

.content h2 {
  color: var(--color-h2-content);
}

.content h3 {
  color: var(--color-h3-content);
}

.content h4 {
  color: var(--color-h4-content);
}

.content .high-text {
  color: var(--color-high-text-content)
}

/* ----------------------------------------------------------------------------------------- */

/********** Logo **********/
.logo {
  display: flex;
  object-fit: contain;
  width: 310px;
  height: 80px;
  align-items: center;
}

.logo img {
  width: 70px;
  height: 70px;
}

.logo a {
  display: inline-flex;
  gap: clamp(10px, 3vw, 20px);
  align-items: center;
  padding-inline: 10px;
}

/* ----------------------------------------------------------------------------------------- */

/********** Buttons **********/
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-family-display);
  font-size: var(--font-size-high-text);
  line-height: 1.2;
  text-align: center;
  text-wrap: balance;
  padding: 0.25em 1em;
  border: none;
  box-shadow: var(--shadow-light);
  transition: 
    background-color 0.2s, 
    color 0.2s, 
    transform 0.2s, 
    box-shadow 0.2s;
}

.btn--square-md {
    border-radius: var(--radius-10);
    width: 200px;
    height: 70px;
}

.btn--square-sm {
    border-radius: var(--radius-10);
    width: 120px;
    height: 40px;
}

.btn--square-lg {
    border-radius: var(--radius-10);
    width: 270px;
    height: 40px;
}

.btn--primary {
  background-color: var(--color-btn-primary-bg);
  color: var(--color-btn-primary-text);
}

.btn--primary:hover,
.btn--primary:focus-visible {
  background-color: var(--color-btn-primary-bg-hover);
  color: var(--color-btn-primary-text-hover);
}

.btn--secondary {
  background-color: var(--color-btn-secondary-bg);
  color: var(--color-btn-secondary-text);
  border: 2px solid var(--color-border-decorative-1);
}

.btn--secondary:hover,
.btn--secondary:focus-visible {
  background-color: var(--color-btn-secondary-bg-hover);
  color: var(--color-btn-secondary-text-hover);
  border: 2px solid var(--color-btn-secondary-border-hover);
}

.btn--third {
  background-color: var(--color-btn-third-bg);
  color: var(--color-btn-third-text);
  border: 2px solid var(--color-border-decorative-2);
}

.btn--third:hover,
.btn--third:focus-visible {
  background-color: var(--color-btn-third-bg-hover);
  color: var(--color-btn-third-text-hover);
  border: 2px solid var(--color-btn-third-border-hover);
}

.btn--primary:active,
.btn--primary:focus-visible:active,
.btn--secondary:active,
.btn--secondary:focus-visible:active,
.btn--third:active,
.btn--third:focus-visible:active {
  transform: translateY(2px) scale(0.98);
}

/* ----------------------------------------------------------------------------------------- */

/********** Header / Navbar **********/

/*** Header ***/
.header-container {
  display: flex;
  width: 100%;
  justify-content: center;
  align-items: center;
}

.header {  /* Class used here for better targeting */
  position: fixed;
  top: 0;
  width: 100%;
  max-width: 1440px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px;
  background-color: var(--color-bg-header);
  border-bottom: 2px solid var(--color-border-decorative-1);
  z-index: var(--z-header);
}

/*** Navigation ***/
.header-nav {
  display: flex;
  justify-content: space-between;
  padding-inline: 40px;
}

.header-nav ul {  /* Configuration with <ul role="list" */
  display: flex;
  width: 100%;
  justify-content: flex-end;
  gap: clamp(40px, 5vw, 60px);
  align-items: center;
}

.header-nav li a {
  white-space: nowrap;
}

.header-nav a {
  font-family: var(--font-family-display);
  font-size: var(--font-size-high-text);
  color: var(--color-text-content);
}

.header-nav a:hover,
.header-nav a:focus-visible {
  border-bottom: 4px solid var(--color-underline);
}

/*** Toggle button ***/
.header-nav-toggle-btn {
  display: none;
  background: none;
  border: none;
}

.header-nav-toggle-btn img {
  width: 50px;
  height: auto;
  min-height: 20px;  /* For Focus is img broken */
}

/*** Responsive ***/
@media (max-width: 880px) {
  .header {
    padding: 10px clamp(10px, 3vw, 30px);
  }

  .header-nav-toggle-btn {
    display: flex;
    align-items: center; 
    justify-content: center;
  }

  .header-nav {
    display: flex;
    opacity: 0;
    visibility: hidden;
    position: absolute;
    top: 100%;
    left: 50%;
    width: 100%;
    padding: 1rem;
    background-color: var(--color-bg-header);
    border-bottom: 2px solid var(--color-border-decorative-1);
    margin-top: 2px;
    transform: translateX(-50%) translateY(-10px);
    transition:
      opacity 0.3s ease,
      transform 0.3s ease,
      visibility 0.3s ease;  
  }

  .header-nav ul {
    flex-direction: column;
    gap: 1rem;
  }

  .header-nav.is-open {  /* Interactivité JS */
    display: flex;
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
  }
}

/* ----------------------------------------------------------------------------------------- */

/********** Footer / Secondary navbar **********/

/*** Global Footer ***/
.footer {  /* Class used here for better targeting */
  max-width: 1440px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  padding: 20px clamp(20px, 3vw, 40px);
  background-color: var(--color-bg-footer);
  color: var(--color-text-content);
  border-top: 2px solid var(--color-border-decorative-1);
}

.footer p,
.footer li {
  margin-block: 1rem;
}

/*** Top of the Footer ***/
.footer-top {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
}

/* Left part (desktop mode) */
.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 30px;
  width: 260px;
  margin-right: 40px;
}

footer .social-networks {
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  align-items: center;
}

footer .social-networks img {
  width: 40px;
  height: 40px;
}

footer .social-networks a {  /* Show focus outline on images */
  display: inline-flex;
  align-items: center;
}

/*Right part (desktop mode) */
.secondary-navigation {
  display: flex;
  flex-direction: row;
  width: 100%;
  gap: clamp(5px, 1vw, 20px);
  margin-right: clamp(20px, 4vw, 40px);
}

.sub-nav {
  display: flex;
  flex-direction: column;
  width: 180px;
}

.sub-nav-title {
  font-size: var(--font-size-high-text);
  color: var(--color-high-text-content);
  font-weight: normal;
}

/*** Bottom of the Footer ***/
.footer-bottom {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  gap: 35px;  /* Minimum space for responsive */
}

/* Left part (desktop mode) */
.copyright {
  max-width: 600px;
  text-wrap: balance;
  align-items: center;
}

/* Right part (desktop mode) */
.legal {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  align-items: center;
  gap: clamp(2rem, 4vw, 3rem);
}

/*** Responsive ***/
@media (max-width: 880px) {
  .footer {
    padding: 30px clamp(20px, 3.5vw, 30px) 20px;
  }

  .footer-top {
    flex-direction: column-reverse;
  }

  .footer-brand {
    width: 100%;
  }

  footer .social-networks {
    gap: 35px;
    justify-content: center;
  }

  .secondary-navigation {
    justify-content: space-evenly;
  }

  .footer-bottom {
    flex-direction: column-reverse;
    gap: 0;
  }

  .copyright {
    max-width: 100%;
  }

  footer .logo, .secondary-navigation, .legal  {
    margin-inline: auto;
  }

  .legal {
    justify-content: space-evenly;
    gap: 20px;
  }

  .copyright, .brand-description, .legal {
    text-align: center;
    text-wrap: balance;
  }
}

@media (max-width: 500px) {
  .secondary-navigation {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
    align-items: center;
  }

  .legal {
    flex-direction: column;
    gap: 0;
  }
  .footer-logo {
    justify-content: center;
  }
}

/* ----------------------------------------------------------------------------------------- */

/********** Hero **********/
.hero {
  max-width: 1440px;
  margin-inline: auto;
  position: relative;
  width: 100%;
  height: 420px;
  overflow: hidden;
  background-color: var(--black);  /* Fallback */
}

.hero img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-content {
  position: absolute;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  gap: clamp(20px, 4vw, 40px);
  padding-inline: clamp(40px, 6vw, 60px);
  margin-block: 0;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  text-wrap: balance;
}

.container-buttons {
  display: flex;
  flex-direction: row;
  justify-content: center;
  gap: 20px 70px;
  margin-inline: auto;
  margin-block: clamp(0px, 2vw, 10px);
  flex-wrap: wrap;
}

p.heading-subtitle {
  letter-spacing: 0.3px;
  margin-block: 0;
  background-color: rgba(var(--black), 0.25);
}

@media (max-width: 880px) {
  .hero {
    height: 600px;
  }
  .hero-content {
  padding-inline: clamp(20px, 5.5vw, 40px);
  }
}

/* ----------------------------------------------------------------------------------------- */

/********** Page "index" **********/
.index-section {
  gap: 40px;
}

.index-sub-section {
  display: flex;
  flex-direction: column;
  gap: clamp(40px, 4.5vw, 60px);
}

.index-description {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-inline: clamp(0px, 1.5vw, 20px);
  text-align: left;
}

.index-values-container {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: clamp(40px, 4.5vw, 60px);
}

.index-values-two-sides {
  display: flex;
  flex-direction: column;
  width: 50%;
  gap: 1rem;
}

.index-values-side-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.index-values-side-text {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.index-value-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-block: 10px;
}

.index-value-block img {
  width: 50px;
  height: 50px;
  border: 1px solid transparent;
}

@media (max-width: 880px) {
  .index-description {
    text-align: center;
  }
  .index-values-container {
    flex-direction: column;
  }
  .index-values-two-sides {
    width: 100%;
  }
  .index-value-block {
    align-items: center;
  }
}

/* ----------------------------------------------------------------------------------------- */

/********** Page "contact" **********/
/*** Global ***/
.contact-section {
  width: 100%;
  display: flex;
  flex-direction: row;
  gap: 50px;
}

.contact-left-side-container,
.contact-right-side-container {
  display: flex;
  flex-direction: column;
  gap: 30px;
  width: 550px;
}

/*** Left side ***/
.contact-block-details {
  display: flex;
  flex-direction: column;
  padding: 20px 30px;
  gap: 50px;
  justify-content: space-between;
  border: 2px solid var(--color-border-decorative-2);
}

.contact-sub-block-details {
  display: flex;
  flex-direction: row;
  gap: 30px;
  align-items: center;
}

.contact-sub-block-details img {
  width: 60px;
  height: 60px;
  border: 1px solid var(--color-border-classic);
}

.contact-details-info {
  display: flex;
  flex-direction: column;
  text-align: left;
  gap: 5px;
}

/*** Right side ***/
.contact-form-container {
  display: flex;
  flex-direction: column;
  gap: 30px;
  padding: 20px 30px;
  border: 2px solid var(--color-border-decorative-2);
}

.form-row-subcontainer {
  display: flex;
  flex-direction: column;
  gap: 15px;  /* Visually = Gap + Space of error message  */
  justify-content: center;
}

.form-block-date-time {
  display: flex;
  flex-direction: row;
  gap: 40px;
}

.form-field-block {
  display: flex;
  flex-direction: row;
  width: 100%;
  justify-content: space-between;
  flex-wrap: wrap;
}

.form-field-block.input-style,
.form-field-block.textarea-style {  /* For space with error message */
  flex-direction: column;
  gap: 6px;
}

.contact-form-container input,
.contact-form-container textarea {
  background-color: var(--white);
  border: 1px solid var(--green);
  border-radius: var(--radius-10);
  padding: 5px 10px;
}

.contact-form-container label {
  min-width: 6.25rem;
  min-height: 25px;
  text-align: left;
}

.contact-form-container input {
  width: 100%;
  min-height: 30px;
}

.contact-form-container textarea {
  width: 100%;
  height: auto;
}

.contact-form-container button[type="submit"] {
  display: inline-block;  /* For margin and size control */
  margin-bottom: 10px;
  margin-inline: auto;
}

.contact-form-container .error-message {
  font-size: 0.875rem;
  text-align: left;
  display: block;   /* For space of error message (block + min-height) */
  min-height: 1rem;
  line-height: 1rem;  /* Avoid small gap between the two horizontal input when error */
}

#form-success {
  display: none;
  min-height: 1.5rem;
  margin-top: 15px;
  text-align: center;
  font-weight: bold;
  color: var(--success-green);
}

@media (max-width: 880px) {
  .contact-section {
    flex-direction: column;
    align-items: center;
  }
  .contact-left-side-container,
  .contact-right-side-container {
    width: clamp(280px, 55vw, 550px);
  }
  .form-block-date-time {
    flex-direction: column;
    gap: 10px;
  }
  .btn--square-lg {
    width: clamp(220px, 40vw, 270px);
  }
}


/* ----------------------------------------------------------------------------------------- */

/********** Page "Menu" **********/
/*** Shop ***/
#shop-user-message {
  padding-block: 25px;
}

.shop-product-cards-container {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  width: 100%;
  justify-content: left;
  gap: clamp(20px, 5vw, 50px);
}

.shop-block-header {
  display: flex;
  flex-direction: column;
  gap: clamp(20px, 6.5vw, 30px);
  margin-block: clamp(20px, 6.5vw, 30px);
}

.shop-product-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 300px;
  padding: 10px;
  border: 1px solid var(--color-border-decorative-1);
  align-items: center;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.shop-top-product-card {
  display: flex;
  flex-direction: column;
  gap: 15px;
  text-align: left;
}

.shop-img-product-card {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border: 1px solid transparent;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.shop-title-product-card {
  color: var(--color-high-text-content);
}

.shop-title-product-card,
.shop-desc-product-card {
  padding-inline: 10px;
}

.shop-bottom-product-card {
  display: flex;
  flex-direction: row;
  width: 100%;
  justify-content: space-between;
  align-items: center;
  padding-inline: 10px;
  padding-block: 20px 10px;
}

.shop-price-product-card {
  font-weight: 600;
}

.shop-product-cards-container article:hover {
  border: 1px solid var(--color-border-decorative-2);
  box-shadow: var(--shadow-subtle);
}

.shop-product-cards-container article:hover img {
  border: 1px solid var(--color-border-decorative-2);
}

.shop-product-cards-container article:hover h3 {
  color: var(--color-h2-content);
}

/*** Cart ***/
.shop-cart {
  width: 300px;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  background: var(--white);
  border: 1px solid var(--green);
}

.shop-cart-title {
  margin-bottom: 1rem;
}

.shop-cart-items {
  display: flex;
  flex-direction: column;
  gap: 15px;
  width: 100%;
}

.cart-line {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  width: 100%;
  gap: 10px;
  align-items: center;
}

.cart-line-info {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.cart-line-name {
  font-weight: 600;
}

.cart-line-price {
  color: var(--black);
}

.cart-line-qty {
  display: flex;
  align-items: center;
  gap: 1px;
}

.cart-line-qty button {
  width: 28px;
  height: 28px;
  padding: 0;
}

.cart-total {
  width: 100%;
  font-weight: 700;
  text-align: right;
  margin-top: 1rem;
}

.shop-cart-footer {
  display: flex;
  flex-direction: column;
  width: 100%;
  align-items: center;
  gap: 1rem;
}

.cart-empty {
  text-align: center;
  color: var(--black);
}

.cart-message {
  display: none;
  margin-top: 1rem;
  padding: 10px;
  text-align: center;
  border: 1px solid var(--green);
  background: rgba(0, 128, 0, 0.08);
  color: var(--green);
  font-weight: 600;
}

.cart-message.is-visible {
  display: block;
}

.shop-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 40px;
  align-items: start;
}

.shop-cart {
  position: sticky;
  top: 120px;
  height: fit-content;
}

@media (max-width: 740px) {
  .shop-layout {
    grid-template-columns: 1fr;
  }

  .shop-product-cards-container {
    flex-direction: column;
  }
  .shop-product-card {
    width: 100%;
  }
  .shop-cart {
    width: 100%;
  }
}

/* ----------------------------------------------------------------------------------------- */

/********** Page "Galerie" **********/
/*** Gallery grid ***/
.gallery { 
  justify-content: center;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 10vw 10vw 10vw 10vw 10vw;
  grid-gap: clamp(30px, 3.5vw, 50px);
}

.gallery .box {
  border: 1px solid var(--color-border-decorative-1);
}

.gallery .box-one {
  grid-column: 1 / 2;
  grid-row: 1 / 5;
}

.gallery .box-two {
  grid-column: 1 / 2;
  grid-row: 5 / 7;
}

.gallery .box-three {
  grid-column: 2 / 3;
  grid-row: 1 / 4;
}

.gallery .box-four {
  grid-column: 2 / 3;
  grid-row: 4 / 7;
}

.gallery .box-five {
  grid-column: 3 / 4;
  grid-row: 1 / 3;
}

.gallery .box-six {
  grid-column: 3 / 4;
  grid-row: 3 / 7;
}

.gallery .box img {
  height: 100%;
  width: 100%;
  object-fit: cover;
  cursor: pointer;
}

@media (max-width: 880px) {
  .gallery { 
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(3, auto);
    grid-gap: 20px;
  }

  .gallery .box {
    grid-column: span 1;
    grid-row: auto;
  }

  .gallery .box-one, .gallery .box-three, .gallery .box-five, .gallery .box-six {
    grid-row: span 2;
  }

  .gallery .box-two, .gallery .box-four {
    grid-row: span 1;
  }
}

@media (max-width: 500px) {
  .gallery { 
    grid-template-columns: 1fr;
    grid-template-rows: repeat(6, auto);
    grid-gap: 20px;
  }

  .gallery .box {
    grid-column: 1 / 2;
    grid-row: auto;
  }
}

/*** Gallery lightbox ***/
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.lightbox-content {
  position: relative;
}

.lightbox img {
  max-width: 90%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 10px;
}

.close-btn {
  position: absolute;
  top: -10px;
  right: -10px;
  background-color: white;
  color: black;
  border: none;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  text-align: center;
  line-height: 30px;
  font-size: 20px;
  cursor: pointer;
}
