/*
Theme Name: Alu Can Alliance
Theme URI: https://alucanalliance.org
Description: Custom theme for the Aluminum Can Alliance — clean, lightweight, no plugin dependencies.
Version: 1.1.0
Author: Alu Can Alliance
Author URI: https://alucanalliance.org
Text Domain: alucan-alliance
*/

/* ===========================
   Fonts (self-hosted)
   ===========================
   Variable woff2 files from Google Fonts (SIL Open Font License),
   latin + latin-ext subsets only. One file covers every weight. */
@font-face {
  font-family: 'Google Sans Flex';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('fonts/google-sans-flex-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Google Sans Flex';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('fonts/google-sans-flex-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('fonts/jetbrains-mono-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('fonts/jetbrains-mono-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ===========================
   CSS Custom Properties
   =========================== */
:root {
  --color-primary: #25B6B8;       /* Alu Can Blue (teal) */
  --color-primary-dark: #000000;  /* Black — footer, buttons */
  --color-primary-light: #5cc9cb; /* Lighter teal — hover states */
  --color-heading: #000000;
  --color-text: #000000;
  --color-text-light: #ffffff;
  --color-bg: #ffffff;
  --color-bg-light: #F2F2F2;
  --color-footer-bg: var(--color-primary-dark);
  --font-heading: 'Google Sans Flex', sans-serif;
  --font-body: 'Google Sans Flex', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --radius-pill: 999px;
  --content-width: 1140px;
}

/* ===========================
   Reset & Base
   =========================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

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

a {
  color: var(--color-primary);
  text-decoration: underline;
}

a:hover {
  color: var(--color-primary-light);
}

/* ===========================
   Header
   =========================== */
.site-header {
  background: var(--color-bg);
  padding: 1rem 0 1.5rem;
}

.site-header .header-inner {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

/* Logo / site branding — reserved space, left side of the header */
.site-branding {
  display: flex;
  align-items: center;
}

.site-branding img {
  height: 60px;
  width: auto;
}

.site-branding-text {
  display: flex;
  align-items: center;
}

/* Header Nav — hamburger menu on mobile, spelled out on desktop (see min-width: 768px below) */

/* Hide the WP menu container and list by default */
.header-nav .menu,
.header-nav > ul,
.header-nav > div {
  list-style: none;
  display: none;
  flex-direction: column;
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--color-primary-dark);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  z-index: 100;
  min-width: 200px;
  margin: 0;
  padding: 1rem 2rem;
}

/* Also hide the ul inside the WP container div */
.header-nav > div > ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

/* Show when toggled open */
.header-nav.open .menu,
.header-nav.open > ul,
.header-nav.open > div {
  display: flex;
  padding: 1rem 2rem;
}

.header-nav a {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  color: #ffffff;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0;
  padding: 0.5rem 0;
  transition: color 0.2s;
}

.header-nav a:hover {
  color: rgba(255,255,255,0.7);
}

.header-nav .current-menu-item a {
  color: rgba(255,255,255,0.7);
}

/* Hamburger toggle — visible on mobile only, hidden on desktop below */
.nav-toggle {
  display: block;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle svg {
  width: 24px;
  height: 24px;
  color: var(--color-text);
}

/* Desktop nav — spelled out in a row instead of the hamburger dropdown */
@media (min-width: 768px) {
  .nav-toggle {
    display: none;
  }

  .header-nav .menu,
  .header-nav > ul,
  .header-nav > div,
  .header-nav > div > ul {
    display: flex;
    flex-direction: row;
    position: static;
    background: none;
    box-shadow: none;
    min-width: 0;
    margin: 0;
    padding: 0;
  }

  .header-nav a {
    color: var(--color-text);
    /* Reserved space for a future submenu indicator — no icon added yet */
    padding: 0.5rem 1.75rem 0.5rem 0;
  }

  .header-nav a:hover,
  .header-nav .current-menu-item a {
    color: var(--color-primary);
  }
}

/* ===========================
   Filmstrip Carousel
   =========================== */
.filmstrip {
  width: 100%;
  overflow: hidden;
  height: 210px;
}

.filmstrip-track {
  display: flex;
  will-change: transform;
}

/* Let each <img> be the flex item, not its <picture> wrapper, so the
   sizing below (and filmstrip.js's width measurements) apply to it. */
.filmstrip-track picture {
  display: contents;
}

.filmstrip-track img {
  height: 210px;
  width: auto;
  margin-right: 3px;
  flex-shrink: 0;
}

.filmstrip-credit {
  width: 100%;
  margin: 0.35rem 0 0;
  padding: 0 1.5rem;
  text-align: right;
  font-size: 0.7rem;
  color: var(--color-heading);
}

/* ===========================
   Main Content
   =========================== */
.site-content {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
  flex: 1;
}

.page-title {
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: 4.5rem;
  color: var(--color-heading);
  margin-top: 12px;
}

/* Read by screen readers and search engines, but not drawn on screen
   (e.g. the homepage's <h1>). WordPress core and plugins also use
   this class name, so themes are expected to define it. */
.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ===========================
   Subtitles
   =========================== */
.subtitle {
  font-family: var(--font-mono);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.9rem;
  color: var(--color-text);
}

/* ===========================
   Buttons
   =========================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--color-primary-dark);
  color: var(--color-text-light);
  font-family: var(--font-mono);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-decoration: none;
  border: none;
  border-radius: var(--radius-pill);
  padding: 0.85rem 1.5rem;
  cursor: pointer;
  transition: opacity 0.2s;
}

.btn:hover {
  opacity: 0.85;
  color: var(--color-text-light);
}

.btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  flex-shrink: 0;
}

.entry-content {
  margin: 12px 75px 60px 0;
  font-size: 1rem;
  line-height: 1.6;
}

.entry-content p {
  margin-bottom: 1.25em;
}

/* Restore list indentation inside content */
.entry-content ul,
.entry-content ol {
  margin: 1.25em 0;
  padding-left: 2em;
}

.entry-content ul ul,
.entry-content ol ol,
.entry-content ul ol,
.entry-content ol ul {
  margin: 0.25em 0;
  padding-left: 1.5em;
}

.entry-content li {
  margin-bottom: 0.35em;
}

blockquote {
  margin: 1.25em 0 1.25em 40px;
}

/* ===========================
   Homepage Recent Posts
   =========================== */
.home-posts {
  margin: 12px 75px 60px 0;
}

.home-post p {
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 1.25em;
}

.home-post-separator {
  border: none;
  border-top: 2px solid var(--color-heading, #000000);
  opacity: 0.6;
  margin: 2em 0;
}

.home .entry-content {
  margin-top: 48px;
}

.home-post::after {
  content: "";
  display: table;
  clear: both;
}

.home-post-thumb {
  border-radius: 8px;
  width: 280px;
  height: 280px;
  object-fit: cover;
}

.home-post-thumb--left {
  float: left;
  margin: 0 1.75rem 1.25rem 0;
}

.home-post-thumb--right {
  float: right;
  margin: 0 0 1.25rem 1.75rem;
}

.home-post-title {
  display: block;
  color: var(--color-primary);
  font-size: 1.3rem;
  margin-bottom: 0.4em;
}

/* ===========================
   Team Grid (About page)
   =========================== */
.team-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2rem 1.5rem;
  margin: 2rem 0;
  list-style: none;
  padding: 0;
}

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

.team-member img {
  width: 150px;
  height: 200px;
  object-fit: cover;
  border-radius: 8px;
  margin: 0 auto 1rem;
}

.team-member .team-role {
  font-weight: 700;
  margin-bottom: 0.25em;
}

.team-member .team-name {
  margin-bottom: 0;
}

.team-member .team-company {
  color: var(--color-heading);
  margin-bottom: 0;
}

@media (max-width: 991px) {
  .team-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 575px) {
  .team-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ===========================
   Static Filmstrip (inner pages)
   =========================== */
.filmstrip-static {
  width: 100%;
  overflow: hidden;
  height: 210px;
}

.filmstrip-static .filmstrip-track {
  animation: none;
}

/* ===========================
   Footer
   =========================== */
.site-footer {
  background: var(--color-footer-bg);
  color: var(--color-text-light);
  font-family: var(--font-mono);
  text-align: center;
  padding: 2rem 0;
  width: 100%;
  flex-shrink: 0;
}

.footer-inner {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.footer-logo {
  flex: 0 0 200px;
  max-width: 200px;
}

.footer-logo img {
  max-width: 180px;
  height: auto;
}

.footer-middle {
  flex: 1;
  text-align: center;
  align-self: flex-start;
}

/* Footer Nav — pipe-separated, no underlines */
.footer-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  justify-content: center;
  align-items: center;
  margin: 0;
  padding: 0;
}

.footer-nav li {
  display: flex;
  align-items: center;
}

.footer-nav li:not(:last-child)::after {
  content: "|";
  color: rgba(255,255,255,0.4);
  margin: 0 0.75rem;
}

.footer-nav a {
  color: var(--color-text-light);
  font-size: 0.9rem;
  text-decoration: none;
  text-transform: uppercase;
  transition: opacity 0.2s;
}

.footer-nav a:hover {
  opacity: 0.7;
}

.footer-address {
  flex: 0 0 200px;
  max-width: 200px;
  text-align: right;
  font-size: 0.85rem;
  line-height: 1.6;
  text-transform: uppercase;
}

.footer-copyright {
  text-align: center;
  font-size: 0.8rem;
  text-transform: uppercase;
  margin-top: 0.75rem;
}

/* Hidden by default (desktop fits on one line); switched on for the
   stacked mobile footer so it wraps exactly where we want it to */
.footer-copyright-break {
  display: none;
}

/* ===========================
   Responsive
   =========================== */
@media (max-width: 1199px) {
  .page-title {
    font-size: 4rem;
  }

  .entry-content,
  .home-posts {
    margin-right: 0;
  }
}

@media (max-width: 991px) {
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .footer-logo,
  .footer-address {
    flex: 0 0 auto;
    max-width: 100%;
  }

  .footer-middle {
    align-self: center;
  }

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

  .footer-copyright-break {
    display: block;
  }

  .footer-copyright-slash {
    display: none;
  }
}

@media (max-width: 767px) {
  /* Smaller, faster filmstrip on mobile */
  .filmstrip {
    height: 90px;
  }

  .filmstrip-track img {
    height: 90px;
  }

  .filmstrip-static {
    height: 90px;
  }

  /* Stack blog post images above the text instead of floating them
     beside it — floated at full size, they squeeze the text column
     too narrow on phones */
  .home-post-thumb,
  .home-post-thumb--left,
  .home-post-thumb--right {
    float: none;
    display: block;
    width: 200px;
    height: 200px;
    max-width: 100%;
    margin: 0 auto 1.25rem;
  }
}

@media (max-width: 575px) {
  .page-title {
    font-size: 3rem;
  }

  .footer-nav ul {
    flex-direction: column;
    gap: 0.5rem;
  }

  .footer-nav li:not(:last-child)::after {
    display: none;
  }
}

/* Collapsible sections (WordPress "Details" block or <details>) */
.entry-content details {
  border-top: 1px solid var(--color-bg-light);
  border-bottom: 1px solid var(--color-bg-light);
  margin: 1.25rem 0;
}

.entry-content details summary {
  position: relative;
  display: block;
  padding: 0.75rem 2rem 0.75rem 0;
  cursor: pointer;
  font-weight: 600;
  text-align: left;
  list-style: none;
}

.entry-content details summary::-webkit-details-marker {
  display: none;
}

.entry-content details summary::after {
  content: "";
  position: absolute;
  right: 0.25rem;
  top: 50%;
  margin-top: -0.45em;
  width: 0.6em;
  height: 0.6em;
  border-right: 2px solid var(--color-primary);
  border-bottom: 2px solid var(--color-primary);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.entry-content details[open] summary::after {
  transform: rotate(-135deg);
}

.entry-content details > :not(summary) {
  margin-bottom: 1rem;
}
