/* Custom Font */
@font-face {
  font-family: "F37GingerThin";
  src: url("assets/F37Ginger-Thin.woff2") format("woff2");
  font-weight: 100;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "F37GingerLight";
  src: url("assets/F37Ginger-Light.woff2") format("woff2");
  font-weight: 100;
  font-style: normal;
  font-display: swap;
}

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

html, body {
  height: 100%;
  width: 100%;
  overflow: hidden;
  background-color: #F6EDDF;
  font-family: "F37GingerLight", sans-serif;
  color: #27211B;
  letter-spacing: 0.5px;
}

.hidden {
  opacity: 0;
  pointer-events: none;
  transition:opacity 1s linear;
}

.fade-in {
  opacity: 1;
  transition:opacity 1s linear;
}

/* Text Highligh */

*::selection {
  background: #27211B;
  color: #F6EDDF;
}
*::-moz-selection {
  background: #27211B;
  color: #F6EDDF;
}
*::-webkit-selection {
  background: #27211B;
  color: #F6EDDF;
}

/* --- INTRO SCREEN --- */

.dot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 30vh;
}

/* Dots */
.corner {
  position: absolute;
  width: 7px;
  height: 7px;
  background-color: #27211B;
  border-radius: 50%;
}

.top-left    { top: 10px; left: 10px; }
.top-center  { top: 10px; left: 50%; transform: translateX(-50%); }
.top-right   { top: 10px; right: 10px; }
.middle-left { top: 50%; left: 10px; transform: translateY(-50%); }
.middle-middle { top: 50%; left: 50%; transform: translateX(-50%) translateY(-50%); }
.middle-right{ top: 50%; right: 10px; transform: translateY(-50%); }
.bottom-left { bottom: 10px; left: 10px; }
.bottom-center{ bottom: 10px; left: 50%; transform: translateX(-50%); }
.bottom-right{ bottom: 10px; right: 10px; }


/* Grid layout (2x2 full height) */
.grid-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  height: 100vh;
  width: 100vw;
}

/* Each grid cell */
.grid-item {
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Title top-left */
.title {
  grid-column: 1;
  grid-row: 1;
  overflow: hidden; /* ensures no overflow past grid cell */
  position: relative;
}

.title h1 {
  position: absolute;
  text-align: center;
  top: 15px;
  left: 25px;
  right: 25px;
  font-size: 5.3vw;
  font-weight: 100;
  font-family: "F37GingerThin";
  white-space: nowrap;
  max-width: 100%; /* ensures it respects grid cell width */

}

/* Description top-right */
.description {
  grid-column: 2;
  grid-row: 1;
  position: relative;
}

.description p {
  position: absolute;
  top: 25px;
  right: 25px;
  left: 25px;
  font-size: 1.2vw;
  line-height: 1.6;
  max-width: 100%; /* ensures it respects grid cell width */
}

/* Footer bottom-left */
.footer {
  grid-column: 1;
  grid-row: 2;
  justify-content: flex-end;
  position: relative;
}

footer {
  position: absolute;
  left: 35px;
  bottom: 25px;
  display: flex;
  gap: 20px;
}

footer a {
  padding-right: 5px;
  text-decoration: none;
  color: #1d1a16;
  font-size: 1.2vw;
}



/* ----- Small devices ----- */

@media only screen and (max-width: 800px) {

    /* Grid layout (1x2 full height) */
    .grid-layout {
        display: grid;
        grid-template-columns: 1fr;
        grid-template-rows: 1fr 1fr;
        height: 100dvh;
        width: 100vw;
        min-height: 100dvh; /* Use dynamic viewport height */
    }

    /* Each grid cell */
    .grid-item {
        padding: 20px;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

 /* Title top-left */
    .title {
        grid-column: 1;
        grid-row: 1;
        overflow: hidden; /* ensures no overflow past grid cell */
        position: relative;
    }

    .title h1 {
        position: absolute;
        text-align: center;
        top: 20px;
        left: 25px;
        right: 25px;
        font-size: 9.8vw;
        font-weight: 100;
        font-family: "F37GingerThin";
        white-space: nowrap;
        max-width: 100%; /* ensures it respects grid cell width */
    }

/* Description top-right */
    .description {
        grid-column: 1;
        grid-row: 2;
        position: relative;
    }

    .description p {
        position: absolute;
        top: 10px;
        right: 30px;
        left: 30px;
        font-size: 3.25vw;
        line-height: 1.6;
        max-width: 100%; /* ensures it respects grid cell width */
    }

    /* Footer bottom-left */
    .footer {
        grid-column: 1;
        grid-row: 2;
        justify-content: flex-end;
        position: relative;
    }

    footer {
        position: absolute;
        left: 30px;
        bottom: 25px;
        display: flex;
        gap: 20px;
    }

    footer a {
        padding-right: 5px;
        text-decoration: none;
        color: #1d1a16;
        font-size: 3.25vw;
    }

    .middle-middle,
    .top-center,
    .bottom-center {
        display: none;
    }


}