/*
Theme Name: Crews Studio
Theme URI: https://crews.studio/
Author: Steve Crews
Description: A responsive portfolio theme with Eurostile-style typography and three-link photographic hero fades.
Version: 1.0.0
Requires at least: 7.0
Tested up to: 7.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: crews-studio
Tags: portfolio, photography, custom-menu, custom-logo, featured-images, responsive-layout
*/

:root {
  --cs-black: #000;
  --cs-white: #fff;
  --cs-muted: rgba(255, 255, 255, 0.78);
  --cs-panel: #161616;
  --cs-border: rgba(255, 255, 255, 0.72);
  --cs-font-display: "Eurostile Extended Local", eurostile-extended, "Eurostile Extended", Eurostile, "Microgramma D Extended", Michroma, Orbitron, Arial, sans-serif;
  --cs-font-body: var(--cs-font-display);
  --cs-header-x: 38px;
  --cs-header-y: 30px;
  --cs-site-title: clamp(34px, 3.9vw, 51px);
  --cs-nav: clamp(16px, 1.5vw, 19px);
  --cs-hero-link: clamp(30px, 4.7vw, 72px);
  --cs-hero-line: 1.4;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--cs-black);
}

body {
  min-height: 100%;
  margin: 0;
  color: var(--cs-white);
  background: var(--cs-black);
  font-family: var(--cs-font-body);
  font-size: 18px;
  line-height: 1.6;
  letter-spacing: 0;
}

body.cs-front-page {
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

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

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.screen-reader-text:focus {
  z-index: 100000;
  top: 12px;
  left: 12px;
  width: auto;
  height: auto;
  padding: 12px 16px;
  clip: auto;
  color: var(--cs-black);
  background: var(--cs-white);
}

.site-header {
  position: relative;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: start;
  width: 100%;
  padding: var(--cs-header-y) var(--cs-header-x);
  background: var(--cs-black);
}

.cs-front-page .site-header {
  position: absolute;
  inset: 0 0 auto;
  background: transparent;
}

.admin-bar.cs-front-page .site-header {
  top: 32px;
}

.site-branding {
  min-width: 0;
}

.site-branding__title {
  display: inline-block;
  max-width: 100%;
  color: var(--cs-white);
  font-family: var(--cs-font-display);
  font-size: var(--cs-site-title);
  font-weight: 400;
  line-height: 1.4;
  letter-spacing: 0;
  text-decoration: none;
}

.site-branding__title:hover,
.site-branding__title:focus-visible {
  color: var(--cs-white);
}

.custom-logo-link {
  display: inline-block;
  max-width: 360px;
}

.custom-logo {
  max-height: 88px;
  width: auto;
}

.site-header__right {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: max-content;
}

.menu-toggle {
  display: none;
}

.primary-navigation {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: max-content;
}

.primary-menu {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  width: auto;
  margin: 0;
  padding: 0;
  list-style: none;
  gap: 24px;
}

.primary-menu li {
  margin: 0;
}

.primary-menu li:first-child {
  text-align: center;
}

.primary-menu li + li {
  margin-left: 0;
}

.primary-menu li:first-child + li {
  margin-left: 0;
}

.primary-menu a {
  display: block;
  padding: 2px 0;
  color: var(--cs-white);
  font-size: var(--cs-nav);
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: 0;
  text-decoration: none;
}

.primary-menu a:hover,
.primary-menu a:focus-visible {
  text-decoration: underline;
}

.site-header__cta,
.wp-block-button__link,
.button,
button,
input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 58px;
  padding: 16px 27px;
  border: 2px solid currentColor;
  border-radius: 0;
  color: var(--cs-white);
  background: transparent;
  font-family: var(--cs-font-display);
  font-size: 16px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0;
  text-decoration: none;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease;
}

.site-header__social {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  transition: color 180ms ease, opacity 180ms ease;
}

.site-header__social svg {
  display: block;
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.site-header__social:hover,
.site-header__social:focus-visible {
  color: var(--cs-white);
  opacity: 1;
  outline: none;
}

.site-header__social:focus-visible {
  box-shadow: 0 0 0 2px var(--cs-white);
}

.site-header__cta {
  flex: 0 0 auto;
  white-space: nowrap;
}

.site-header__cta:hover,
.site-header__cta:focus-visible,
.wp-block-button__link:hover,
.wp-block-button__link:focus-visible,
.button:hover,
.button:focus-visible,
button:hover,
button:focus-visible,
input[type="submit"]:hover,
input[type="submit"]:focus-visible {
  color: var(--cs-black);
  background: var(--cs-white);
  border-color: var(--cs-white);
}

.cs-hero {
  position: relative;
  display: flex;
  min-height: 100vh;
  overflow: hidden;
  color: var(--cs-white);
  background: #38383b;
}

@supports (min-height: 100svh) {
  .cs-hero {
    min-height: 100svh;
  }
}

.cs-hero__bg,
.cs-hero__hover-bg {
  position: absolute;
  inset: -1px;
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
}

.cs-hero__bg {
  z-index: 0;
  background-image: var(--cs-default-bg);
  background-position: var(--cs-default-position, center center);
}

.cs-hero__hover-bg {
  z-index: 1;
  background-position: var(--cs-hero-position, center center);
  opacity: 0;
  transition: opacity 900ms ease;
}

.cs-hero__hover-bg.is-active {
  opacity: 1;
}

.cs-hero__scrim {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: rgba(0, 0, 0, 0.12);
  pointer-events: none;
}

.cs-hero__items {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 100vh;
  padding: 136px var(--cs-header-x) 38px;
}

@supports (min-height: 100svh) {
  .cs-hero__items {
    min-height: 100svh;
  }
}

.cs-hero__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: min(100%, 1188px);
  margin: 0;
  padding: 64px;
  column-gap: clamp(22px, 3vw, 42px);
  row-gap: 0;
  list-style: none;
}

.cs-hero__item {
  margin: 0;
}

.cs-hero__link {
  display: block;
  padding: 25px 0;
  color: rgba(255, 255, 255, 0.86);
  font-family: var(--cs-font-display);
  font-size: var(--cs-hero-link);
  font-weight: 400;
  line-height: var(--cs-hero-line);
  letter-spacing: 0;
  text-decoration: none;
  white-space: nowrap;
  transition: color 220ms ease, opacity 220ms ease;
}

.cs-hero__link:hover,
.cs-hero__link:focus-visible,
.cs-hero__link.is-active {
  color: var(--cs-white);
  outline: none;
}

.cs-hero__link:focus-visible span {
  box-shadow: 0 0 0 2px var(--cs-white);
}

@media (orientation: portrait) {
  .cs-hero__bg {
    background-position: var(--cs-default-portrait-position, var(--cs-default-position, center center));
  }

  .cs-hero__hover-bg {
    background-position: var(--cs-hero-portrait-position, var(--cs-hero-position, center center));
  }
}

.site-main {
  min-height: 55vh;
}

.cs-content {
  width: min(100% - 48px, 980px);
  margin: 0 auto;
  padding: 72px 0 96px;
}

.cs-content--wide {
  width: min(100% - 48px, 1188px);
}

.cs-content h1,
.cs-content h2,
.cs-content h3,
.entry-title {
  margin: 0 0 24px;
  color: var(--cs-white);
  font-family: var(--cs-font-display);
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: 0;
}

.entry-title {
  font-size: 52px;
}

.cs-content p,
.cs-content li {
  color: var(--cs-muted);
}

.cs-content a {
  color: var(--cs-white);
}

.entry-featured-image {
  margin: 0 0 36px;
}

.archive-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  margin-top: 48px;
}

.archive-card {
  color: var(--cs-white);
  text-decoration: none;
}

.archive-card__media {
  aspect-ratio: 1 / 1;
  margin-bottom: 18px;
  overflow: hidden;
  background: var(--cs-panel);
}

.archive-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 500ms ease;
}

.archive-card:hover .archive-card__media img,
.archive-card:focus-visible .archive-card__media img {
  transform: scale(1.04);
}

.archive-card__title {
  margin: 0;
  font-size: 24px;
  font-weight: 400;
  line-height: 1.25;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 108px;
  padding: 34px var(--cs-header-x);
  color: var(--cs-white);
  background: var(--cs-black);
  text-align: center;
}

.site-footer p {
  max-width: 1060px;
  margin: 0;
  font-size: var(--cs-nav);
  line-height: 1.6;
  color: var(--cs-white);
}

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

@media (max-width: 1180px) {
  :root {
    --cs-site-title: clamp(32px, 3.7vw, 43px);
    --cs-hero-link: clamp(28px, 4.6vw, 58px);
  }

  .site-header {
    gap: 20px;
  }

  .cs-hero__list {
    padding: 48px;
  }
}

@media (max-width: 860px) {
  :root {
    --cs-header-x: 24px;
    --cs-header-y: 24px;
    --cs-site-title: 34px;
    --cs-hero-link: clamp(34px, 8.6vw, 48px);
    --cs-nav: 24px;
  }

  .site-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
  }

  .custom-logo-link {
    max-width: 230px;
  }

  .site-header__right,
  .primary-navigation {
    min-width: 0;
  }

  .menu-toggle {
    position: relative;
    z-index: 42;
    display: inline-flex;
    width: 44px;
    min-height: 44px;
    padding: 0;
    border: 0;
    color: var(--cs-white);
    background: transparent;
  }

  .menu-toggle:hover,
  .menu-toggle:focus-visible {
    color: var(--cs-white);
    background: transparent;
  }

  .menu-toggle__bar,
  .menu-toggle__bar::before {
    display: block;
    width: 26px;
    height: 1px;
    background: currentColor;
    content: "";
    transition: transform 180ms ease;
  }

  .menu-toggle__bar::before {
    transform: translateY(8px);
  }

  .site-header.is-menu-open .menu-toggle__bar {
    transform: rotate(45deg);
  }

  .site-header.is-menu-open .menu-toggle__bar::before {
    transform: rotate(90deg);
  }

  .primary-navigation {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 32px;
    padding: 96px 28px 48px;
    background: rgba(0, 0, 0, 0.96);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 180ms ease, transform 180ms ease;
  }

  .site-header.is-menu-open .primary-navigation {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .primary-menu {
    flex-direction: column;
    align-items: center;
    width: auto;
    gap: 12px;
  }

  .primary-menu li,
  .primary-menu li + li,
  .primary-menu li:first-child + li {
    margin-left: 0;
  }

  .primary-menu li:first-child {
    flex-basis: auto;
  }

  .primary-menu a {
    font-size: var(--cs-nav);
    line-height: 1.3;
  }

  .site-header__cta {
    font-size: 16px;
  }

  .cs-hero__items {
    padding-top: 112px;
  }

  .cs-hero__list {
    padding: 24px;
    gap: 0;
  }

  .cs-hero__link {
    padding: 12px 0;
    line-height: 1.2;
    text-align: center;
  }

  .entry-title {
    font-size: 40px;
  }

  .archive-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
  }
}

@media (max-width: 560px) {
  :root {
    --cs-site-title: 29px;
    --cs-hero-link: 38px;
  }

  .site-branding__title {
    line-height: 1.16;
  }

  .cs-hero__items {
    padding-right: 18px;
    padding-left: 18px;
  }

  .cs-hero__list {
    flex-direction: column;
    width: 100%;
    padding: 18px 0;
  }

  .archive-grid {
    grid-template-columns: 1fr;
  }

  .cs-content {
    width: min(100% - 36px, 980px);
    padding-top: 52px;
  }

  .site-footer {
    padding-right: 24px;
    padding-left: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
