/*
Theme Name: Daniel Lee Portfolio
Template: astra
Version: 1.0.0
Description: Custom child theme for Daniel Lee's storyboard artist portfolio.
Author: Daniel Lee
*/

/* CSS custom properties — used throughout all sections */
:root {
  --color-bg:         #ffffff;
  --color-accent:     #c0392b;
  --color-text:       #1a1a1a;
  --color-text-muted: #666666;
  --color-border:     #f0f0f0;
  --font-serif:       'Playfair Display', Georgia, serif;
  --font-sans:        'Helvetica Neue', Arial, sans-serif;
  --nav-height:       64px;
  --container-width:  1100px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Astra resets — override Astra's container and body defaults */
.ast-container,
.site-content,
#content,
.ast-page-builder-template {
  max-width: none !important;
  padding: 0 !important;
}

/* Remove Astra's default page padding */
.entry-content,
.ast-article-single {
  padding: 0 !important;
  margin: 0 !important;
}

/* === TYPOGRAPHY === */
h1, h2, h3 {
  font-family: var(--font-serif);
  color: var(--color-text);
  line-height: 1.2;
}

p {
  color: var(--color-text-muted);
  line-height: 1.75;
}

a {
  color: inherit;
  text-decoration: none;
}

/* === LAYOUT UTILITIES === */
.dlp-container {
  max-width: var(--container-width);
  margin-inline: auto;
  padding-inline: 40px;
}

.dlp-section {
  padding-block: 80px;
  scroll-margin-top: var(--nav-height);
}

.dlp-label {
  font-family: var(--font-sans);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 12px;
  display: block;
}

.dlp-section__heading {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  margin-bottom: 40px;
}

/* === BUTTONS === */
.dlp-btn {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 12px 24px;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  cursor: pointer;
  border: 1px solid transparent;
}

.dlp-btn--primary {
  background: var(--color-accent);
  color: #fff;
  border-color: var(--color-accent);
}

.dlp-btn--primary:hover {
  background: #a93226;
  border-color: #a93226;
}

.dlp-btn--outline {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-text);
}

.dlp-btn--outline:hover {
  background: var(--color-text);
  color: #fff;
}

/* === STICKY NAV === */
.dlp-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  height: var(--nav-height);
}

.dlp-nav__inner {
  max-width: var(--container-width);
  margin-inline: auto;
  padding-inline: 40px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dlp-nav__brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-decoration: none;
}

.dlp-nav__name {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: 0.02em;
}

.dlp-nav__title {
  font-family: var(--font-sans);
  font-size: 9px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.dlp-nav__links {
  display: flex;
  list-style: none;
  gap: 32px;
}

.dlp-nav__link {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #555;
  transition: color 0.2s;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
}

.dlp-nav__link:hover,
.dlp-nav__link.dlp-active {
  color: var(--color-accent);
  border-bottom-color: var(--color-accent);
}

/* Hamburger — hidden on desktop */
.dlp-nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.dlp-nav__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  transition: transform 0.25s, opacity 0.25s;
}

/* Hamburger open state */
.dlp-nav__hamburger[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.dlp-nav__hamburger[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.dlp-nav__hamburger[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Push page content below fixed nav */
#dlp-main {
  padding-top: var(--nav-height);
}

/* Mobile nav — styles added in Task 12 */

/* === HERO === */
.dlp-hero {
  min-height: calc(90vh - var(--nav-height));
  display: flex;
  align-items: center;
  background: var(--color-bg);
}

.dlp-hero__inner {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 48px;
  align-items: center;
  width: 100%;
}

.dlp-hero__headline {
  font-size: clamp(2.5rem, 5vw, 3.75rem);
  line-height: 1.1;
  margin-bottom: 20px;
}

.dlp-hero__rule {
  width: 36px;
  height: 2px;
  background: var(--color-accent);
  margin-bottom: 20px;
}

.dlp-hero__bio {
  max-width: 420px;
  margin-bottom: 32px;
  font-size: 15px;
}

.dlp-hero__ctas {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.dlp-hero__image {
  display: flex;
  justify-content: center;
}

.dlp-hero__image img {
  width: 100%;
  max-width: 440px;
  height: auto;
  display: block;
  border: 1px solid var(--color-border);
  object-fit: cover;
}

/* === PORTFOLIO === */
.dlp-portfolio {
  background: #fafafa;
}

/* Filter tabs */
.dlp-filter {
  display: flex;
  gap: 0;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--color-border);
}

.dlp-filter__tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  padding: 10px 20px;
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #999;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}

.dlp-filter__tab:hover {
  color: var(--color-accent);
}

.dlp-filter__tab--active {
  color: var(--color-accent);
  border-bottom-color: var(--color-accent);
}

/* Masonry grid — CSS columns approach */
.dlp-gallery {
  columns: 3;
  column-gap: 16px;
}

.dlp-gallery__item {
  break-inside: avoid;
  margin-bottom: 16px;
  position: relative;
  overflow: hidden;
}

.dlp-gallery__item a {
  display: block;
  position: relative;
}

.dlp-gallery__item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.35s ease;
}

.dlp-gallery__item:hover img {
  transform: scale(1.03);
}

/* Hover overlay */
.dlp-gallery__overlay {
  position: absolute;
  inset: 0;
  background: rgba(26, 26, 26, 0.72);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 16px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.dlp-gallery__item:hover .dlp-gallery__overlay {
  opacity: 1;
}

.dlp-gallery__title {
  font-family: var(--font-serif);
  font-size: 15px;
  color: #fff;
  margin-bottom: 4px;
}

.dlp-gallery__tag {
  font-family: var(--font-sans);
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.dlp-gallery__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 32px;
  color: #fff;
  opacity: 0.85;
}

/* Hidden filter state */
.dlp-gallery__item[aria-hidden="true"] {
  display: none;
}

/* === ABOUT === */
.dlp-about__inner {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: 64px;
  align-items: start;
}

.dlp-about__image img {
  width: 100%;
  max-width: 320px;
  height: auto;
  display: block;
  object-fit: cover;
  border: 1px solid var(--color-border);
}

.dlp-about__bio {
  margin-bottom: 36px;
  font-size: 15px;
}

/* Skills list — 2 column grid */
.dlp-skills-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 24px;
  list-style: none;
  margin-bottom: 36px;
}

.dlp-skills-list li {
  font-family: var(--font-sans);
  font-size: 13px;
  color: var(--color-text);
  padding-left: 12px;
  position: relative;
}

.dlp-skills-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 4px;
  background: var(--color-accent);
  border-radius: 50%;
}

/* Education */
.dlp-edu-item {
  margin-bottom: 16px;
  padding-left: 12px;
  border-left: 2px solid var(--color-accent);
}

.dlp-edu-item strong {
  display: block;
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--color-text);
  margin-bottom: 2px;
}

.dlp-edu-item span {
  font-family: var(--font-sans);
  font-size: 12px;
  color: var(--color-text-muted);
}

/* === RESUME === */
.dlp-resume {
  background: #fafafa;
}

.dlp-resume__block {
  margin-bottom: 64px;
}

.dlp-resume__block:last-child {
  margin-bottom: 0;
}

.dlp-resume__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--color-border);
}

.dlp-resume__header h3 {
  font-family: var(--font-serif);
  font-size: 1.4rem;
}

.dlp-resume__viewer {
  width: 100%;
  overflow: hidden;
}

.dlp-resume__viewer iframe {
  width: 100%;
  height: 800px;
  border: 1px solid var(--color-border);
  display: block;
}

/* === CONTACT === */
.dlp-contact__inner {
  text-align: center;
}

.dlp-contact__tagline {
  font-size: 16px;
  margin-bottom: 48px;
}

.dlp-contact__links {
  display: flex;
  gap: 32px;
  justify-content: center;
  flex-wrap: wrap;
}

.dlp-contact__link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 24px 40px;
  border: 1px solid var(--color-border);
  transition: border-color 0.2s, background 0.2s;
  min-width: 220px;
}

.dlp-contact__link:hover {
  border-color: var(--color-accent);
  background: #fff9f9;
}

.dlp-contact__link-label {
  font-family: var(--font-sans);
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.dlp-contact__link-value {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--color-text);
}

/* === FOOTER === */
.dlp-footer {
  background: var(--color-text);
  padding-block: 32px;
}

.dlp-footer .dlp-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.dlp-footer__copy {
  font-family: var(--font-sans);
  font-size: 12px;
  color: #888;
}

.dlp-footer__links {
  display: flex;
  gap: 24px;
}

.dlp-footer__links a {
  font-family: var(--font-sans);
  font-size: 12px;
  color: #888;
  transition: color 0.2s;
}

.dlp-footer__links a:hover {
  color: var(--color-accent);
}

/* =========================================
   RESPONSIVE — tablet and mobile overrides
   ========================================= */

/* --- TABLET: 768px – 1024px --- */
@media (max-width: 1024px) {
  .dlp-container {
    padding-inline: 24px;
  }

  .dlp-hero__inner {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .dlp-gallery {
    columns: 2;
  }

  .dlp-about__inner {
    gap: 40px;
  }
}

/* --- MOBILE: < 768px --- */
@media (max-width: 767px) {
  :root {
    --nav-height: 56px;
  }

  .dlp-container {
    padding-inline: 20px;
  }

  .dlp-section {
    padding-block: 56px;
  }

  /* Nav — show hamburger, hide links by default */
  .dlp-nav__hamburger {
    display: flex;
  }

  .dlp-nav__links {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: var(--color-bg);
    flex-direction: column;
    gap: 0;
    border-bottom: 1px solid var(--color-border);
    padding: 12px 0;
  }

  .dlp-nav__links.dlp-nav__links--open {
    display: flex;
  }

  .dlp-nav__links li {
    padding: 0;
  }

  .dlp-nav__link {
    display: block;
    padding: 14px 24px;
    border-bottom: none;
  }

  /* Hero — single column, image below text */
  .dlp-hero__inner {
    grid-template-columns: 1fr;
  }

  .dlp-hero__image {
    order: -1;
  }

  .dlp-hero__image img {
    max-width: 100%;
    max-height: 260px;
    object-fit: cover;
  }

  .dlp-hero__bio {
    max-width: 100%;
  }

  /* Gallery — single column */
  .dlp-gallery {
    columns: 1;
  }

  /* Filter tabs — allow horizontal scroll */
  .dlp-filter {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .dlp-filter::-webkit-scrollbar {
    display: none;
  }

  .dlp-filter__tab {
    white-space: nowrap;
    padding: 10px 14px;
  }

  /* About — single column */
  .dlp-about__inner {
    grid-template-columns: 1fr;
  }

  .dlp-about__image img {
    max-width: 100%;
    max-height: 280px;
    object-fit: cover;
  }

  /* Skills — single column on mobile */
  .dlp-skills-list {
    grid-template-columns: 1fr;
  }

  /* Resume — smaller iframe height */
  .dlp-resume__viewer iframe {
    height: 500px;
  }

  .dlp-resume__header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  /* Contact links — stack vertically */
  .dlp-contact__links {
    flex-direction: column;
    align-items: center;
  }

  .dlp-contact__link {
    width: 100%;
    max-width: 320px;
  }

  /* Footer — center everything */
  .dlp-footer .dlp-container {
    flex-direction: column;
    text-align: center;
  }
}
