/* Import custom fonts */
@font-face {
  font-family: 'MADE Tommy Soft';
  src: url('../fonts/woff2/MADE Tommy Soft Thin.woff2') format('woff2');
  font-weight: 100; /* Thin weight */
  font-style: normal;
}

@font-face {
  font-family: 'MADE Tommy Soft';
  src: url('../fonts/woff2/MADE Tommy Soft Light.woff2') format('woff2');
  font-weight: 300; /* Light weight */
  font-style: normal;
}

@font-face {
  font-family: 'MADE Tommy Soft';
  src: url('../fonts/woff2/MADE Tommy Soft Regular.woff2') format('woff2');
  font-weight: 400; /* Regular weight */
  font-style: normal;
}

@font-face {
  font-family: 'MADE Tommy Soft';
  src: url('../fonts/woff2/MADE Tommy Soft Medium.woff2') format('woff2');
  font-weight: 500; /* Medium weight */
  font-style: normal;
}

@font-face {
  font-family: 'MADE Tommy Soft';
  src: url('../fonts/woff2/MADE Tommy Soft Bold.woff2') format('woff2');
  font-weight: 700; /* Bold weight */
  font-style: normal;
}

@font-face {
  font-family: 'MADE Tommy Soft';
  src: url('../fonts/woff2/MADE Tommy Soft ExtraBold.woff2') format('woff2');
  font-weight: 800; /* Extra Bold weight */
  font-style: normal;
}

@font-face {
  font-family: 'MADE Tommy Soft';
  src: url('../fonts/woff2/MADE Tommy Soft Black.woff2') format('woff2');
  font-weight: 900; /* Black weight */
  font-style: normal;
}

:root {
  --blue: #0066FF;
  --blue-darker: hsl(220, 100%, 40%);
}

/* General styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Apply the custom font globally */
body {
  font-family: 'MADE Tommy Soft', Arial, sans-serif;
  background: #f4f4f4;
}

h1 {
  font-family: 'MADE Tommy Soft';
  font-weight: bold;
  color: var(--blue);
}

h2 {
  font-family: 'MADE Tommy Soft';
  font-weight: 700; 
}

p {
  font-family: 'MADE Tommy Soft';
  font-weight: 400; 
}


a {
  font-family: 'MADE Tommy Soft';
}

header {
  border-bottom: 1.8px solid var(--blue);
}

/* Desktop Header */
.desktop-header {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
}

.desktop-header .logo {
  text-align: center;
}

.desktop-header .nav-links {
  padding-left: 3rem; /* Adds spacing to the left of the nav-links */
}

.desktop-header .nav-links a {
  position: relative;
  padding-right: 1.5rem;
  color: black;
  text-decoration: none;
  font-weight: 500;
  font-size: 17px;
}

.desktop-header .nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 36%;
  transform: translateX(-50%) scaleX(0);
  width: 100%;
  height: 2.4px;
  background-color: var(--blue);
  transform-origin: center;
  transition: transform 0.3s ease, opacity 0.3s ease;
  opacity: 0;
}

.desktop-header .nav-links a:hover::after {
  opacity: 1; 
  transform: translateX(-50%) scaleX(1); 
}

.desktop-header .header-button {
  text-align: right;
  padding-right: 2rem;
}

.desktop-header .header-button a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: var(--blue);
  color: white;
  text-decoration: none;
  border-radius: 12px;
  transition: background-color 0.3s ease;
  font-size: 17px;
  font-weight: 500;
}

.desktop-header .header-button a:hover {
  background-color: var(--blue-darker);
}

/* Mobile Header */
.mobile-header {
  display: grid;
  grid-template-columns: 1fr 2fr;
  align-items: center;
  position: relative;
}

.mobile-header .logo {
  text-align: left;
  height: 130px;
  background-position: left;
}

.mobile-header .close-menu {
  display: none;
  cursor: pointer;
}

.hamburger {
  display: flex; /* Flexbox for centering lines */
  flex-direction: column; /* Stack the lines vertically */
  justify-content: space-between; /* Space out the lines */
  align-items: center; /* Center the lines horizontally */
  width: 45px; /* Container width */
  height: auto;
  cursor: pointer; /* Pointer cursor for interactivity */
  position: relative; /* Needed for pseudo-elements */
  margin-left: 2rem;
}

.hamburger::before,
.hamburger::after,
.hamburger span {
  content: ''; /* Empty content for the lines */
  display: block;
  width: 100%; /* Full width of the container */
  height: 2px; /* Thickness of the lines */
  background-color: var(--blue); /* Use your custom blue color */
  transition: transform 0.3s ease, background-color 0.3s ease; /* Smooth animation */
  border-radius: 2px; /* Optional: Rounded edges for lines */
}

/* Spacing for the middle line */
.hamburger span {
  margin: 10px 0; /* Adds spacing between the lines */
}

.close-menu {
  display: none; /* Hidden by default */
  position: relative; /* Needed for pseudo-elements */
  width: 45px; /* Matches hamburger width */
  height: 45px; /* Matches hamburger height */
  cursor: pointer;
  z-index: 99;
  margin-left: 2rem; /* Matches hamburger's position */
}

.close-menu::before,
.close-menu::after {
  content: ''; /* Empty content for the lines of the X */
  position: absolute;
  top: 50%; /* Center vertically */
  left: 50%; /* Center horizontally */
  width: 100%; /* Full width of the container */
  height: 2.5px; /* Thickness of the lines */
  background-color: var(--blue); /* Use your custom blue color */
  border-radius: 2px; /* Optional: Rounded edges for lines */
  transform-origin: center; /* Anchor for rotation */
  transition: transform 0.3s ease, background-color 0.3s ease; /* Smooth animation */
}

/* X shape: Top-left to bottom-right line */
.close-menu::before {
  transform: translate(-50%, -50%) rotate(45deg); /* Rotate 45 degrees */
}

/* X shape: Top-right to bottom-left line */
.close-menu::after {
  transform: translate(-50%, -50%) rotate(-45deg); /* Rotate -45 degrees */
}

.mobile-header .nav-links {
  display: none;
  flex-direction: column;
  align-items: center;
  position: absolute;
  top: 130px;
  left: 0;
  right: 0;
  background-color: #f4f4f4;
}

.mobile-header .nav-links a {
  position: relative;
  color: black;
  text-decoration: none;
  margin-bottom: 20px;
  font-weight: 500;
  font-size: 20px;
}

.mobile-header .nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 130%;
  height: 2px;
  background-color: var(--blue);
  transition: transform 0.3s ease, opacity 0.3s ease;
  opacity: 0;
  
}

.mobile-header .nav-links a:hover::after,
.mobile-header .nav-links a:focus::after,
.mobile-header .nav-links a:active::after {
  transform: translateX(-50%) scaleX(1);
  opacity: 1;
}

.mobile-header .nav-links.show {
  display: flex;
  border-bottom: 1.8px solid var(--blue);
}

.mobile-header .header-button {
  display: none;
  margin-top: 1rem;
  text-align: center;
}

.mobile-header .header-button.show {
  display: block;
}

.mobile-header .header-button a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: var(--blue);
  color: white;
  text-decoration: none;
  border-radius: 12px;
  transition: background-color 0.3s ease;
}

.mobile-header .header-button a:hover {
  background-color: var(--blue);
}

/* Active link underline */
.desktop-header .nav-links a.active::after,
.mobile-header .nav-links a.active::after {
  opacity: 1;
  transform: translateX(-50%) scaleX(1);
}

.vector {
  background-size: contain; 
  background-repeat: no-repeat; 
  background-position: center; 
  width: 100%; 
  height: 60vh; 
  max-width: 620px;
}

.vector img {
  width: 100%;
  padding: 0 2rem;
}

.logo {
  background-image: url('../images/logo-kat_blue.svg'); 
  background-size: contain;
  background-repeat: no-repeat; 
  background-position: center;
  width: 100%; 
  height: 150px;
}

.content-row {
  display: flex;
  flex-direction: column;
  gap: 2rem; /* Spacing between rows */
}

.arrow-divider {
  display: flex;
  justify-content: center;
}

.arrow-divider svg {
  width: 30px; /* Adjust width for better scaling */
  height: auto; /* Maintain aspect ratio */
}

/* Curve Divider Styles */
.curve-divider {
  position: relative;
  width: 100%;
  height: 450px; 
  overflow: hidden;
  z-index: 1;
  margin-top: -40px;
}

/* SVG as a background */
.curve-divider svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1; /* Behind the content */
}

/* Text on top of the curve */
.curve-divider .curve-content {
  position: absolute;
  top: 60%; /* Center vertically */
  left: 50%; /* Center horizontally */
  transform: translate(-50%, -50%);
  text-align: center;
  color: white;
  z-index: 2; /* Above the SVG */
}

.curve-divider p {
  font-family: 'MADE Tommy Soft';
  font-size: 20px;
  line-height: 1.4em;
  font-weight: 500;
  margin: 0;
  max-width: 50rem;
}

/* Fake Rectangle Styles */
.rectangle-divider {
  display: none; /* Hidden by default */
  background-color: var(--blue);
  width: 100%; /* Full width */
  height: 50px; /* Default height */
  z-index: 0; /* Behind other content */
}

/* Fake Rectangle Styles */
.footer-rectangle-divider {
  display: none; /* Hidden by default */
  background-color: var(--blue);
  width: 100%; /* Full width */
  height: 50px; /* Default height */
  z-index: 0; /* Behind other content */
  margin-top: -40px;
}

.footer .footer-content {
  position: relative;
  width: 100%;
  height: 250px; 
  overflow: hidden;
  z-index: 1;
  margin-top: -40px;
}

/* Works Section */
.works-section {
  text-align: center;
  padding: 3rem;
  background-color: #f4f4f4;
}

.works-section h2 {
  font-size: 3rem;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 2.5rem;
}

/* Grid Layout */
.works-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin: auto;
}

/* Work Items (Project Buttons) */
.work-item {
  position: relative;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
  color: white;
  text-decoration: none;
  aspect-ratio: 1 / 1;
  padding: 0;
  transition: transform 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Overlay using ::before */
.work-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background-color: rgba(0, 102, 255, 0); /* initially invisible */
  transition: background-color 0.3s ease;
  z-index: 1;
}

/* Title styling */
.work-item .work-title {
  position: relative;
  z-index: 2;
  opacity: 0;
  font-size: 2rem;
  font-weight: 600;
  color: white;
  text-align: center;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

/* On hover or click */
.work-item:hover::before,
.work-item.clicked::before {
  background-color: rgba(0, 102, 255, 0.7);
}

.work-item:hover .work-title,
.work-item.clicked .work-title {
  opacity: 1;
}

.disabled-work {
  background-color: var(--blue);
  color: white;
  cursor: default;
  pointer-events: none;
  font-size: 1.6rem;
  font-weight: 600;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  transition: none;
  position: relative;
}

/* Remove all hover effects */
.disabled-work::before,
.disabled-work .work-title {
  display: none;
}

.disabled-work:hover {
  background-color: var(--blue); /* No hover tint */
}

/* Footer Section */
.footer {
  position: relative;
  color: white;
  text-align: center;
  padding-top: 120px;
  margin-top: 4rem;
  overflow: hidden; 
}

/* Footer Background */
.footer-bg {
  position: absolute;
  top: -1px; /* Slight overlap */
  left: 0;
  width: 100%;
  height: auto;
  z-index: 0;
}

.footer-bg svg {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100vw; /* Prevents overflow */
  preserveAspectRatio: xMidYMax meet; /* Keeps aspect ratio */
}

/* Footer Content */
.footer-content {
  position: relative;
  z-index: 1; /* Ensure content is above SVG */
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 6rem;
}

/* Left Column: Navigation Links */
.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, auto); /* Two equal columns */
  column-gap: 4rem; /* Adds horizontal space only */
  row-gap: 2rem; /* Ensures no vertical gap */
  text-align: left;
}

.footer-nav a {
  color: white;
  text-decoration: none;
  font-size: 1.2rem;
  transition: color 0.3s ease;
}

.footer-nav a:hover {
  color: var(--blue-darker);
}

/* Middle Column: Logo */
.footer-logo {
  background-image: url('../images/logo kat_blue with border.svg'); /* White logo version */
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  width: 120px;
  height: 120px;
  margin: auto;
}

/* Right Column: Social Media Icons */
.footer-social {
  display: flex;
  gap: 1rem;
  justify-content: right;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: #f4f4f4;
}

.social-icon img {
  width: 60%;
  height: auto;
}

/* Hover Effects */
.social-icon:hover {
  transform: scale(1.1);
  background-color: var(--blue-darker);
}


/* Small Devices (Mobile) */
@media (max-width: 700px) {
  .mobile-header {
    display: grid;
    grid-template-columns: 1fr 2fr!important;
  }

  h1 {
    text-align: center;
    font-size: 45px;
    font-weight: 600;
    line-height: 45px;
  }

  .content-row {
    display: block;
  }

  .content-row .text {
    margin-top: 30px;
  }

  .vector {
    height: 40vh;
    max-height: 500px;
    margin: auto;
    margin-top: 25px;
  }

  .vector img {
    width: 100%;
    padding: 0 2rem;
  }

  .arrow-divider {
    margin-top: 3em;
  }

  .arrow-divider svg {
    width: 15px;
  }

  .rectangle-divider {
    display: block;
    height: 230px; 
    margin-top: -300px;
  }

  .footer-rectangle-divider {
    display: block;
    height: 150px; 
  }

  .curve-divider svg {
    position: absolute;
    top: 50px;
    left: 0;
    width: 100%;
    height: 30%;
    z-index: 1;
  }

  .curve-divider .curve-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    z-index: 2;
    width: 80%;
  }

  .curve-divider p {
    font-size: 0.9rem!important;
    line-height: 1.2rem!important;
  }

  .footer-bg svg {
    margin-top: 10px;
  }

  .footer .footer-content {
    position: absolute;
    top: 60%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    z-index: 2;
    width: 100%;
    margin-top: -10px;
  }
  
  .works-section {
    padding: 2rem;
  }

  .works-grid {
    grid-template-columns: 1fr; /* One project per row */
  }

  .work-item {
    padding: 3rem;
    font-size: 1.5rem;
  }

  .work-item .work-title {
    opacity: 0;
    transition: opacity 0.3s ease;
    font-size: 1.4rem;
    text-align: center;
  }

  .work-item:active::before,
  .work-item.clicked::before {
    background-color: rgba(0, 102, 255, 0.7);
  }

  .work-item:active .work-title,
  .work-item.clicked .work-title {
    opacity: 1;
  }

  .footer-content {
    display: grid;
    grid-template-columns: 1fr auto 1fr; /* Three columns: left, center, right */
    align-items: center;
    justify-items: center;
    text-align: center;
    gap: 1rem;
    width: 100%;
    padding: 1.5rem;
  }

  .footer-nav {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.8rem;
  }

  .footer-logo {
    width: 100px;
    height: 100px;
    background-size: contain;
    background-position: center;
    margin-left: 12px;
  }

  .footer-social {
    display: flex;
    flex-direction: column; /* Stack icons vertically */
    align-items: flex-end; /* Align to the right */
    gap: 0.5rem; /* Adjust spacing between icons */
  }

  .social-icon {
    width: 36px; /* Make icons smaller */
    height: 36px;
  }

  .social-icon svg {
    width: 26px; /* Adjust SVG size */
    height: 26px;
  }
}

/* Medium Devices (Tablets) */
@media (min-width: 701px) and (max-width: 768px) {
  .desktop-header {
    display: none;
  }

  header {
    /* border-bottom: none; */
  }

  h1 {
    font-size: 65px;
    text-align: center;
    margin-top: 15px;
    margin-bottom: 40px;
  }

  .content-row {
    display: block;
  }

  .vector {
    height: 50vh;
    max-height: 800px;
    margin: auto;
  }

  .mobile-header {
    grid-template-columns: 1fr 1.5fr;
  }

  .mobile-header .logo {
    height: 160px;
  }

  .mobile-header .nav-links {
    top: 160px;
  }

  .curve-divider p {
    font-size: 15px;
  }

  .curve-divider h4 {
    font-size: 1rem;
    line-height: 1.2rem;
  }

  .arrow-divider {
    margin-top: 40px;
  }

  .arrow-divider svg {
    width: 25px;
  }

  .works-section {
    padding: 2rem;
  }

  .works-grid {
    gap: 1.2rem;
  }

  .work-item {
    padding: 3rem;
    font-size: 1.5rem;
  }

  .footer {
    padding-top: 0;
  }

  .footer-rectangle-divider {
    display: block;
    height: 80px; 
    margin-top: -80px;
  }

  .footer .footer-content {
    margin-top: 40px;
  }
}

/* Large Devices (Small Desktops) */
@media (min-width: 769px) {
  h1 {
    padding-left: 4rem;
    font-size: 4rem;
    line-height: 4rem;
    padding-top: 4rem;
  }

  .mobile-header {
    display: none;
  }

  .desktop-header {
    display: grid;
  }

  .content-row {
    display: grid;
    grid-template-columns: 1fr 1fr; 
    gap: 0.5rem;
    align-items: center; 
    padding-top: 15px;
  }

  .content-row .text {
    grid-column: 1; 
    text-align: left; 
    font-size: 3rem; 
    margin: auto;
    height: 60vh;
  }

  .content-row .vector {
    grid-column: 2; /* Place in the second column */
    background-size: contain; /* Ensure the image fits within the column */
    background-position: left;
    margin-left: -2rem;
    height: 60vh;
  }

  .arrow-divider {
    margin-top: -4rem;
  }

  .footer {
    padding-top: 0;
  }

  .footer-rectangle-divider {
    display: block;
    height: 80px; 
    margin-top: -80px;
  }

  .footer .footer-content {
    margin-top: 40px;
  }
}

/* Ensure proper visibility of headers across breakpoints */
@media (max-width: 1024px) {
  .desktop-header {
    display: none;
  }

  .mobile-header {
    display: grid;
    grid-template-columns: 2fr 2.5fr;
  }

  .curve-divider h4 {
    font-size: 1.2rem;
    line-height: 1.4rem;
  }

  .curve-divider p {
    font-size: 1.2rem;
    line-height: 1.4rem;
  }

  .hamburger {
    width: 40px; 
  }

  .mobile-header .nav-links {
    font-size: 18px; 
  }
}

/* Extra Large Devices (Large Desktops) */
@media (min-width: 1025px) {
  h1 {
    padding-left: 4rem;
    padding-top: 8rem;
    font-size: 90px;
    line-height: 100px;
  }

  .mobile-header {
    display: none;
  }

  .desktop-header {
    display: grid;
  }

  .content-row {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Two equal columns */
    gap: 2rem; /* Space between the columns */
    align-items: center; /* Vertically center the content */
    padding-top: 15px;
  }

  .content-row.text {
    grid-column: 1; /* Place in the first column */
    text-align: left; /* Align text to the left (optional) */
    font-size: 3rem; /* Adjust font size for better emphasis */
    margin: auto;
    height: 60vh;
  }

  .content-row.vector {
    grid-column: 2; /* Place in the second column */
    background-size: contain; /* Ensure the image fits within the column */
    background-position: left;
    margin-left: 0;
    height: 60vh;
  }

  .arrow-divider {
    margin-top: 0;
  }
  .footer {
    padding-top: 50px;
  }
} 

/* Interaction styles across breakpoints */
@media (max-width: 700px),
(min-width: 701px) and (max-width: 768px),
(min-width: 769px) and (max-width: 1024px),
(min-width: 1025px) {
  .work-item .work-title {
    opacity: 0;
    transition: opacity 0.3s ease;
    text-align: center;
    z-index: 2;
    position: relative;
    pointer-events: none;
  }

  .work-item::before {
    content: '';
    position: absolute;
    inset: 0;
    background-color: rgba(0, 102, 255, 0);
    transition: background-color 0.3s ease;
    z-index: 1;
  }

  .work-item:hover::before,
  .work-item.clicked::before,
  .work-item:active::before {
    background-color: rgba(0, 102, 255, 0.7);
  }

  .work-item:hover .work-title,
  .work-item.clicked .work-title,
  .work-item:active .work-title {
    opacity: 1;
  }
}

@media (max-width: 1366px) and (orientation: landscape),
       (min-width: 1025px) and (max-height: 800px) {
  h1 {
    font-size: 80px;
    padding-top: 3rem;
    line-height: 80px;
  }

  .vector {
    height: 35vh;
    max-width: 500px;
    margin-top: 0;
  }

  .vector img {
    padding: 0 2rem;
    margin-left: 2rem;
  }

  .logo {
    height: 130px;
  }

  .desktop-header .nav-links a {
    padding-right: 1.4rem;
  }
  .curve-divider {
    height: 400px;
    margin-top: -10px;
  }
}