/* Khalid Alabri - coaching website
   Hand-written styles for all three pages. */

:root {
  --navy: #1f203a;
  --accent: #ffa54d;
  --accent-dark: #e98a2b;
  --text: #1f2030;
  --text-soft: #55566a;
  --grey: #f2f2f2;
  --grey-dark: #e5e5e5;
  --white: #ffffff;
  --radius: 10px;
}

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

body {
  font-family: 'Tajawal', Arial, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  background: var(--navy);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 12px;
  padding-bottom: 12px;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px 20px;
  list-style: none;
}

.nav-links a {
  display: inline-block;
  padding: 8px 2px;
  color: var(--white);
  font-weight: 500;
  text-decoration: none;
  border-bottom: 2px solid transparent;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* Buttons */
.button {
  display: inline-block;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.button-accent {
  background: var(--accent);
  color: var(--navy);
}

.button-accent:hover {
  background: var(--accent-dark);
}

.button-outline {
  border: 2px solid var(--navy);
  color: var(--navy);
}

.button-outline:hover {
  background: var(--navy);
  color: var(--white);
}

/* Home: introduction */
.intro {
  text-align: center;
  padding-bottom: 56px;
  /* Grey band behind the top half of the portrait */
  background: linear-gradient(var(--grey) 190px, var(--white) 190px);
}

.portrait {
  width: 240px;
  height: 240px;
  margin: 0 auto 24px;
  border-radius: 50%;
  border: 8px solid var(--white);
  object-fit: cover;
  position: relative;
  top: 40px;
  margin-bottom: 56px;
}

.intro h1 {
  font-size: clamp(1.7rem, 5vw, 2.4rem);
  margin-bottom: 12px;
}

.intro p {
  max-width: 420px;
  margin: 0 auto;
  color: var(--text-soft);
}

.intro-tag {
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.9rem;
}

/* Home: partner section */
.partner {
  padding: 56px 0;
  background: linear-gradient(var(--white) 55%, var(--grey-dark) 55%);
}

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

.partner h2 {
  font-size: clamp(1.6rem, 4.5vw, 2.4rem);
  line-height: 1.3;
  margin-bottom: 24px;
}

.partner img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--radius);
}

.partner-photo .button {
  display: block;
  margin-top: 24px;
}

/* Home: booking */
.booking {
  padding: 80px 0;
}

.booking-inner {
  max-width: 640px;
  text-align: center;
}

.booking h2 {
  font-size: clamp(2rem, 7vw, 3.4rem);
  line-height: 1.25;
  margin-bottom: 20px;
}

.booking p {
  font-size: 1.2rem;
  margin-bottom: 28px;
}

/* Photo grids (home and album) */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  list-style: none;
}

.photo-grid img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: var(--radius);
  transition: opacity 0.2s ease;
}

.photo-grid a:hover img {
  opacity: 0.85;
}

/* On the home page the photos run edge to edge */
.photo-grid-home {
  gap: 0;
}

.photo-grid-home img {
  border-radius: 0;
}

/* Home: social links */
.social {
  padding: 64px 0;
  background: var(--grey-dark);
  text-align: center;
}

.social h2 {
  font-size: 1.2rem;
  font-weight: 500;
  margin-bottom: 20px;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  list-style: none;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  color: #000;
  border-radius: 50%;
  transition: transform 0.2s ease;
}

.social-links a:hover {
  transform: scale(1.12);
}

/* Contact and album pages */
.page-section {
  padding: 48px 0 64px;
}

.page-section h1 {
  font-size: clamp(1.6rem, 5vw, 2.2rem);
  text-align: center;
  margin-bottom: 28px;
}

.contact-form {
  display: block;
  width: 100%;
  height: 1000px;
  border: 0;
}

/* Footer */
.site-footer {
  background: var(--navy);
  color: var(--white);
  text-align: center;
  padding: 20px;
  font-size: 0.85rem;
}

/* Tablets and phones */
@media (max-width: 760px) {
  .partner {
    background: var(--white);
    padding: 40px 0;
  }

  .partner-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .booking {
    padding: 56px 0;
  }

  .photo-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .photo-grid-home {
    gap: 0;
  }
}

@media (max-width: 420px) {
  .header-inner {
    flex-direction: column;
  }

  .nav-links {
    justify-content: center;
    gap: 0 14px;
    font-size: 0.95rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
