/* ============================================================
   STREET TREES — Page components
   Extends styles.css for the full multi-page template
   (nav dropdowns, inner-page headers, blog, portfolio, shop,
   forms, team, stats, contact, tables, alerts).
   Load AFTER styles.css. Driven entirely by tokens.css.
   ============================================================ */

/* ---------------- Nav dropdowns (multi-page menu) ---------------- */
.nav__item { position: relative; }
.nav__item > .nav__link { display: inline-flex; align-items: center; gap: .3rem; cursor: pointer; }
.nav__caret { width: .85rem; height: .85rem; transition: transform var(--dur) var(--ease); }
.nav__dropdown {
  position: absolute; top: 100%; left: 0; min-width: 12rem; margin-top: .6rem;
  background: var(--st-paper); border: 2px solid var(--st-line); border-radius: var(--radius);
  padding: .5rem; display: none; z-index: 60; box-shadow: var(--shadow-md);
}
.nav__dropdown a { display: block; padding: .55rem .8rem; font-family: var(--font-display); font-weight: 500; font-size: .92rem; color: var(--ink-600); border-radius: var(--radius-sm); transition: color var(--dur), background var(--dur); }
.nav__dropdown a:hover { color: var(--st-orange); background: var(--st-orange-soft); }
.nav__item:hover .nav__dropdown { display: block; }
.nav__item:hover .nav__caret { transform: rotate(180deg); }
/* mobile: dropdown groups become labeled sections */
.nav__mobile .nav__group-label { display: block; margin-top: .75rem; font-family: var(--font-display); font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .14em; color: var(--st-orange); }
.nav__mobile .nav__dropdown { position: static; display: block; background: none; border: none; box-shadow: none; padding: 0 0 0 .75rem; margin: .25rem 0; }

/* ---------------- Inner-page header + breadcrumb ---------------- */
.page-header {
  position: relative; padding: 9rem 0 4rem; overflow: hidden; text-align: center;
  border-bottom: 2px solid var(--st-line); background: var(--st-cream-deep);
}
.page-header.deco-pattern::after { content: ""; position: absolute; inset: 0; background: var(--sky-wash); pointer-events: none; }
.page-header__inner { position: relative; z-index: 2; max-width: 46rem; margin-inline: auto; }
.page-header h1 { font-size: clamp(2.2rem, 4.4vw, 3.2rem); margin-bottom: 1rem; }
.page-header p { color: var(--ink-600); font-size: 1.08rem; }
.breadcrumb { display: flex; gap: .5rem; justify-content: center; align-items: center; margin-top: 1.25rem; font-size: .86rem; color: var(--ink-400); }
.breadcrumb a { color: var(--ink-600); }
.breadcrumb a:hover { color: var(--st-orange); }
.breadcrumb .sep { color: var(--st-line-strong); }

/* ---------------- Layout helpers ---------------- */
.grid { display: grid; gap: 1.5rem; }
.grid--2 { grid-template-columns: 1fr; }
.grid--3 { grid-template-columns: 1fr; }
.grid--4 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--st-paper); border: 2px solid var(--st-line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease-soft), border-color var(--dur);
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); border-color: var(--st-orange-soft); }
@media (min-width: 640px) { .grid--2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 768px) { .grid--3 { grid-template-columns: repeat(3, 1fr); } .grid--4 { grid-template-columns: repeat(4, 1fr); } }

/* ---------------- Blog ---------------- */
.post-card { display: flex; flex-direction: column; overflow: hidden; }
.post-card__media { aspect-ratio: 16 / 10; background: linear-gradient(135deg, var(--st-orange-soft), var(--st-pink-soft)); position: relative; overflow: hidden; }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; }
.post-card__cat { position: absolute; top: .75rem; left: .75rem; z-index: 2; }
.post-card__body { padding: 1.5rem; display: flex; flex-direction: column; gap: .6rem; }
.post-card__title { font-family: var(--font-display); font-size: 1.25rem; color: var(--ink-900); }
.post-card__title a:hover { color: var(--st-orange); }
.post-meta { display: flex; flex-wrap: wrap; gap: 1rem; font-size: .8rem; color: var(--ink-400); }
.post-meta span { display: inline-flex; align-items: center; gap: .35rem; }
.post-excerpt { font-size: .95rem; color: var(--ink-600); }
.read-more { font-family: var(--font-display); font-weight: 600; font-size: .88rem; color: var(--st-orange); }
.read-more:hover { color: var(--st-sienna); }

/* article / prose (blog-single) */
.prose { max-width: 46rem; margin-inline: auto; color: var(--ink-800); }
.prose > * + * { margin-top: 1.4rem; }
.prose h2 { font-family: var(--font-display); font-size: 1.8rem; color: var(--ink-900); margin-top: 2.5rem; }
.prose h3 { font-family: var(--font-display); font-size: 1.35rem; color: var(--ink-900); margin-top: 2rem; }
.prose p { line-height: 1.85; }
.prose a { color: var(--st-orange); text-decoration: underline; text-underline-offset: 3px; }
.prose a:hover { color: var(--st-sienna); }
.prose img { width: 100%; border-radius: var(--radius); }
.prose blockquote { border-left: 4px solid var(--st-orange); padding: .25rem 0 .25rem 1.25rem; font-style: italic; color: var(--ink-800); }
.prose ul, .prose ol { padding-left: 1.25rem; display: flex; flex-direction: column; gap: .5rem; }
.prose ul { list-style: disc; } .prose ol { list-style: decimal; }
.prose code { font-family: var(--font-mono); font-size: .85em; background: var(--st-cream-deep); padding: .15em .4em; border-radius: 6px; }

/* pagination */
.pagination { display: flex; gap: .5rem; justify-content: center; margin-top: 3rem; }
.pagination a, .pagination span {
  min-width: 2.6rem; height: 2.6rem; display: inline-flex; align-items: center; justify-content: center;
  border: 2px solid var(--st-line); border-radius: var(--radius-pill); color: var(--ink-600); font-family: var(--font-display); font-weight: 500; font-size: .95rem;
}
.pagination a:hover { border-color: var(--st-orange); color: var(--st-orange); }
.pagination .is-active { background: var(--st-orange); color: #fff; border-color: transparent; }

/* ---------------- Portfolio / gallery (artsy) ---------------- */
.filter-bar { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; margin-bottom: 2.5rem; }
.filter-bar button {
  padding: .55rem 1.2rem; font-family: var(--font-display); font-weight: 500; font-size: .88rem;
  border: 2px solid var(--st-line); border-radius: var(--radius-pill); color: var(--ink-600); transition: all var(--dur);
}
.filter-bar button:hover { color: var(--ink-900); border-color: var(--st-line-strong); }
.filter-bar button.is-active { background: var(--st-orange); color: #fff; border-color: transparent; }
.portfolio-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
.tile { position: relative; overflow: hidden; aspect-ratio: 4 / 3; border-radius: var(--radius-lg); background: linear-gradient(135deg, var(--st-orange-soft), var(--st-yellow-soft)); cursor: pointer; box-shadow: var(--shadow-sm); }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-slow) var(--ease-soft); }
.tile:hover img { transform: scale(1.06); }
.tile__overlay {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end;
  padding: 1.25rem; background: linear-gradient(to top, rgba(47,42,32,.82), transparent 60%);
  opacity: 0; transition: opacity var(--dur) var(--ease-soft);
}
.tile:hover .tile__overlay { opacity: 1; }
.tile__title { font-family: var(--font-display); color: #fff; font-size: 1.15rem; }
.tile__cat { font-family: var(--font-display); font-size: .78rem; color: var(--st-yellow); font-weight: 600; letter-spacing: .06em; }
@media (min-width: 640px) { .portfolio-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .portfolio-grid { grid-template-columns: repeat(3, 1fr); } }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(47,42,32,.9); display: none; align-items: center; justify-content: center; padding: 2rem; }
.lightbox.open { display: flex; }
.lightbox img, .lightbox__frame { max-width: min(90vw, 60rem); max-height: 85vh; border-radius: var(--radius-lg); }
.lightbox__close { position: absolute; top: 1.25rem; right: 1.5rem; color: #fff; }
.lightbox__close:hover { color: var(--st-yellow); }

/* ---------------- Shop ---------------- */
.product-card { display: flex; flex-direction: column; overflow: hidden; }
.product-card__media { aspect-ratio: 1 / 1; background: linear-gradient(135deg, var(--st-pink-soft), var(--st-orange-soft)); position: relative; overflow: hidden; }
.product-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-slow) var(--ease-soft); }
.product-card:hover .product-card__media img { transform: scale(1.05); }
.product-card__badge { position: absolute; top: .75rem; left: .75rem; z-index: 2; }
.product-card__body { padding: 1.1rem 1.25rem 1.4rem; display: flex; flex-direction: column; gap: .4rem; }
.product-card__title { font-size: 1.05rem; color: var(--ink-900); font-family: var(--font-display); }
.product-card__title a:hover { color: var(--st-orange); }
.price { display: flex; align-items: baseline; gap: .5rem; }
.price__now { font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; color: var(--st-sienna); }
.price__was { font-size: .88rem; color: var(--ink-400); text-decoration: line-through; }
.stars { display: inline-flex; gap: .1rem; color: var(--st-yellow); }
.stars svg { width: .95rem; height: .95rem; fill: currentColor; }
.stars .empty { color: var(--st-line-strong); fill: currentColor; }

/* product detail */
.product-detail { display: grid; gap: 2.5rem; grid-template-columns: 1fr; }
.product-gallery__main { aspect-ratio: 1/1; background: linear-gradient(135deg, var(--st-pink-soft), var(--st-orange-soft)); border-radius: var(--radius-lg); overflow: hidden; }
.product-gallery__main img { width:100%; height:100%; object-fit: cover; }
.product-gallery__thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; margin-top: .75rem; }
.product-gallery__thumbs .tile { aspect-ratio: 1/1; border-radius: var(--radius); }
.product-info h1 { font-size: 2.1rem; margin-bottom: .75rem; }
.qty { display: inline-flex; border: 2px solid var(--st-line); border-radius: var(--radius-pill); overflow: hidden; }
.qty button { width: 2.6rem; height: 2.8rem; color: var(--ink-800); font-size: 1.15rem; }
.qty button:hover { background: var(--st-orange-soft); color: var(--st-orange); }
.qty input { width: 3rem; text-align: center; background: none; border: none; border-inline: 2px solid var(--st-line); color: var(--ink-900); }
.cart-table { width: 100%; border-collapse: collapse; }
.cart-table th, .cart-table td { text-align: left; padding: 1rem; border-bottom: 2px solid var(--st-line-faint); font-size: .95rem; }
.cart-table th { font-family: var(--font-display); text-transform: uppercase; letter-spacing: .08em; font-size: .74rem; color: var(--ink-400); }
@media (min-width: 900px) { .product-detail { grid-template-columns: 1fr 1fr; } }

/* ---------------- Forms ---------------- */
.form-grid { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .form-grid.cols-2 { grid-template-columns: 1fr 1fr; } }
.form-group { display: flex; flex-direction: column; gap: .4rem; }
.form-group.full { grid-column: 1 / -1; }
.label { font-family: var(--font-display); font-weight: 500; font-size: .84rem; letter-spacing: .02em; color: var(--ink-600); }
.input, .textarea, .select {
  width: 100%; padding: .8rem 1.05rem; background: var(--st-paper); border: 2px solid var(--st-line);
  color: var(--ink-900); font: inherit; font-size: .98rem; border-radius: var(--radius); transition: border-color var(--dur), box-shadow var(--dur);
}
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--st-orange); box-shadow: 0 0 0 4px var(--st-orange-soft); }
.input::placeholder, .textarea::placeholder { color: var(--ink-300); }
.textarea { resize: vertical; min-height: 8rem; }
.checkbox { display: inline-flex; gap: .6rem; align-items: flex-start; font-size: .92rem; color: var(--ink-600); }
.checkbox input { margin-top: .2rem; accent-color: var(--st-orange); width: 1.05rem; height: 1.05rem; }

/* ---------------- Team / stats / contact ---------------- */
.member { text-align: center; padding: 2rem 1.75rem; }
.member__avatar { width: 6rem; height: 6rem; margin: 0 auto 1rem; border-radius: 50%; background: var(--warm-gradient); display: grid; place-items: center; font-family: var(--font-display); font-weight: 600; font-size: 1.7rem; color: #fff; overflow: hidden; box-shadow: var(--shadow-pop); }
.member__avatar img { width: 100%; height: 100%; object-fit: cover; }
.member__name { font-family: var(--font-display); font-size: 1.15rem; color: var(--ink-900); }
.member__role { font-family: var(--font-display); font-weight: 500; font-size: .86rem; color: var(--st-orange); letter-spacing: .04em; }
.member__socials { display: flex; gap: .75rem; justify-content: center; margin-top: .75rem; color: var(--ink-400); }
.member__socials a:hover { color: var(--st-orange); }

.stat { text-align: center; padding: 1.5rem; }
.stat__num { font-family: var(--font-display); font-size: 3rem; font-weight: 700; color: var(--st-orange); }
.stat__label { font-family: var(--font-display); font-weight: 500; font-size: .86rem; color: var(--ink-600); letter-spacing: .04em; margin-top: .35rem; }

.info-list { display: flex; flex-direction: column; gap: 1.5rem; }
.info-list li { display: flex; gap: 1rem; align-items: flex-start; }
.info-list .info-ico { flex-shrink: 0; width: 3rem; height: 3rem; display: grid; place-items: center; border-radius: 42% 58% 60% 40% / 55% 42% 58% 45%; background: var(--st-orange-soft); color: var(--st-sienna); }
.info-list h4 { font-family: var(--font-display); font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-400); margin-bottom: .25rem; }
.info-list p { color: var(--ink-800); font-size: .98rem; }
.map-embed { aspect-ratio: 16/9; width: 100%; border-radius: var(--radius-lg); background: repeating-linear-gradient(45deg, var(--st-cream-deep), var(--st-cream-deep) 12px, var(--st-paper-warm) 12px, var(--st-paper-warm) 24px); border: 2px solid var(--st-line); display: grid; place-items: center; color: var(--ink-400); font-family: var(--font-display); font-size: .9rem; letter-spacing: .06em; }

/* ---------------- Tables / alerts / misc ---------------- */
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 1rem; border-bottom: 2px solid var(--st-line-faint); text-align: left; font-size: .95rem; color: var(--ink-800); }
.table th { font-family: var(--font-display); text-transform: uppercase; letter-spacing: .08em; font-size: .74rem; color: var(--ink-400); }
.table .tick { color: var(--st-olive); } .table .cross { color: var(--ink-300); }

.alert { padding: 1rem 1.25rem; border: 2px solid var(--st-line); border-left-width: 5px; border-radius: var(--radius); font-size: .95rem; background: var(--st-paper); }
.alert--info { border-left-color: var(--st-orange); color: var(--ink-800); }
.alert--success { border-left-color: var(--st-olive); color: var(--ink-800); }
.alert--warn { border-left-color: var(--st-yellow); color: var(--ink-800); }

.tag { display: inline-flex; align-items: center; padding: .25rem .7rem; font-family: var(--font-display); font-weight: 500; font-size: .76rem; color: var(--ink-600); border: 2px solid var(--st-line); border-radius: var(--radius-pill); }
.tag:hover { color: var(--st-orange); border-color: var(--st-orange); }
