/**
 * Ambiant Housing & Construction Pvt. Ltd.
 * Components CSS: Header, Buttons, Cards, Modals, Timeline, Forms & Footer
 */

/* ==========================================================================
   1. GLOBAL HEADER & NAVBAR
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background-color: rgba(12, 14, 17, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: var(--z-nav);
  transition: background-color var(--transition-fast), border-color var(--transition-fast), height var(--transition-fast);
}

.site-header.scrolled {
  background-color: rgba(12, 14, 17, 0.96);
  border-bottom-color: var(--border-medium);
  box-shadow: var(--shadow-sm);
}

.nav-container {
  max-width: var(--container-wide);
  height: 100%;
  margin: 0 auto;
  padding: 0 var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-link {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.brand-logo-img {
  height: 38px;
  width: auto;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.nav-list {
  display: flex;
  align-items: center;
  gap: var(--space-6);
}

.nav-link {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  padding: var(--space-2) 0;
  position: relative;
  transition: color var(--transition-fast);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0%;
  height: 1.5px;
  background-color: var(--accent-gold);
  transition: width var(--transition-fast);
}

.nav-link:hover {
  color: var(--text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-link.active {
  color: var(--accent-gold);
  font-weight: 600;
}

/* Nav Actions (CTA Button) */
.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

/* Mobile Toggle */
.mobile-nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  background: var(--bg-surface);
  transition: border-color var(--transition-fast);
}

.mobile-nav-toggle:hover {
  border-color: var(--accent-gold);
}

/* ==========================================================================
   2. MOBILE NAVIGATION DRAWER
   ========================================================================== */
.mobile-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  max-width: 380px;
  height: 100vh;
  background-color: var(--bg-surface);
  border-left: 1px solid var(--border-medium);
  z-index: var(--z-drawer);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: right var(--transition-normal);
  box-shadow: var(--shadow-lg);
}

.mobile-drawer.open {
  right: 0;
}

.mobile-drawer-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  z-index: calc(var(--z-drawer) - 1);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-fast), visibility var(--transition-fast);
}

.mobile-drawer-backdrop.open {
  opacity: 1;
  visibility: visible;
}

.mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: var(--space-6);
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-drawer-close {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  border-radius: var(--radius-xs);
}

.mobile-drawer-close:hover {
  color: var(--text-primary);
  border-color: var(--accent-gold);
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-top: var(--space-6);
}

.mobile-nav-link {
  display: block;
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  font-weight: 600;
  color: var(--text-secondary);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-nav-link.active {
  color: var(--accent-gold);
}

/* ==========================================================================
   3. ARCHITECTURAL BUTTONS
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.75rem 1.6rem;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-radius: var(--radius-xs);
  text-decoration: none;
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.btn-primary {
  background-color: var(--accent-gold);
  color: #0C0E11;
  border: 1px solid var(--accent-gold);
  font-weight: 700;
}

.btn-primary:hover {
  background-color: var(--accent-gold-light);
  border-color: var(--accent-gold-light);
  color: #000000;
  box-shadow: 0 4px 20px rgba(194, 162, 111, 0.35);
  transform: translateY(-1px);
}

.btn-secondary {
  background-color: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  border: 1px solid var(--border-strong);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: var(--accent-gold);
  color: var(--accent-gold-light);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--accent-gold);
  border: 1px solid var(--accent-gold-border);
}

.btn-outline:hover {
  background: var(--accent-gold-glow);
  border-color: var(--accent-gold);
  color: var(--text-primary);
}

.btn-sm {
  padding: 0.5rem 1.1rem;
  font-size: 0.7rem;
}

.btn-lg {
  padding: 0.95rem 2.2rem;
  font-size: var(--text-sm);
}

.btn-icon-arrow::after {
  content: '→';
  display: inline-block;
  transition: transform var(--transition-fast);
}

.btn-icon-arrow:hover::after {
  transform: translateX(4px);
}

/* ==========================================================================
   4. CARDS & ARCHITECTURAL CONTAINERS
   ========================================================================== */
.card-arch {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: var(--space-8);
  position: relative;
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
}

.card-arch:hover {
  background-color: var(--bg-card-hover);
  border-color: var(--border-accent);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

/* Corner Architectural Crosshair Accents */
.card-arch-framed {
  position: relative;
}

.card-arch-framed::before {
  content: '';
  position: absolute;
  top: -1px;
  left: -1px;
  width: 12px;
  height: 12px;
  border-top: 2px solid var(--accent-gold);
  border-left: 2px solid var(--accent-gold);
}

.card-arch-framed::after {
  content: '';
  position: absolute;
  bottom: -1px;
  right: -1px;
  width: 12px;
  height: 12px;
  border-bottom: 2px solid var(--accent-gold);
  border-right: 2px solid var(--accent-gold);
}

/* Expertise Card Specifics */
.expertise-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.expertise-card-header {
  margin-bottom: var(--space-4);
}

.expertise-icon-box {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--accent-gold);
  border-radius: var(--radius-xs);
  margin-bottom: var(--space-4);
}

.expertise-card-title {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-2);
  color: var(--text-primary);
}

.expertise-card-subtitle {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--accent-gold);
  margin-bottom: var(--space-3);
  letter-spacing: 0.05em;
}

.expertise-card-desc {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-6);
}

.expertise-scope-list {
  margin-top: auto;
  border-top: 1px solid var(--border-subtle);
  padding-top: var(--space-4);
}

.expertise-scope-item {
  font-size: var(--text-xs);
  color: var(--concrete-light);
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}

.expertise-scope-item::before {
  content: '▪';
  color: var(--accent-gold);
  font-size: 10px;
}

/* ==========================================================================
   5. PROJECT SHOWCASE & FILTER
   ========================================================================== */
.filter-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-10);
  padding: var(--space-2);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  max-width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.filter-btn {
  padding: 0.5rem 1.1rem;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--radius-xs);
  transition: all var(--transition-fast);
  letter-spacing: 0.08em;
}

.filter-btn:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.filter-btn.active {
  color: #0C0E11;
  background-color: var(--accent-gold);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: var(--space-8);
}

.project-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.project-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.project-media-wrapper {
  position: relative;
  aspect-ratio: 16 / 10;
  background-color: var(--bg-surface-elevated);
  overflow: hidden;
}

.project-media-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.project-card:hover .project-media-img {
  transform: scale(1.04);
}

.project-category-tag {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  background: rgba(12, 14, 17, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-accent);
  color: var(--accent-gold);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  padding: 4px 8px;
  text-transform: uppercase;
}

.project-card-body {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.project-card-title {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-2);
}

.project-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--border-subtle);
}

.project-card-desc {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-6);
  flex-grow: 1;
}

/* ==========================================================================
   6. APPROACH PIPELINE (PLAN -> DESIGN -> BUILD -> MANAGE)
   ========================================================================== */
.approach-pipeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-6);
  position: relative;
}

.pillar-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  position: relative;
}

.pillar-step {
  font-family: var(--font-mono);
  font-size: var(--text-3xl);
  font-weight: 800;
  color: var(--accent-gold);
  opacity: 0.6;
  margin-bottom: var(--space-2);
}

.pillar-title {
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.pillar-subtitle {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin-bottom: var(--space-3);
}

.pillar-desc {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-4);
}

.pillar-items {
  border-top: 1px solid var(--border-subtle);
  padding-top: var(--space-3);
  margin-top: auto;
}

.pillar-item {
  font-size: var(--text-xs);
  color: var(--concrete-light);
  margin-bottom: var(--space-1);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.pillar-item::before {
  content: '›';
  color: var(--accent-gold);
  font-weight: 700;
}

/* ==========================================================================
   7. CAREER TIMELINE COMPONENT
   ========================================================================== */
.timeline-track {
  position: relative;
  max-width: 860px;
  margin: 0 auto;
  padding: var(--space-8) 0;
}

.timeline-track::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 32px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent-gold) 0%, var(--border-medium) 100%);
}

.timeline-entry {
  position: relative;
  padding-left: 80px;
  margin-bottom: var(--space-10);
}

.timeline-node {
  position: absolute;
  left: 24px;
  top: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background-color: var(--bg-primary);
  border: 2px solid var(--accent-gold);
  box-shadow: 0 0 10px rgba(194, 162, 111, 0.4);
}

.timeline-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: var(--space-6);
  transition: border-color var(--transition-fast);
}

.timeline-card:hover {
  border-color: var(--border-accent);
}

.timeline-year-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--accent-gold);
  background: rgba(194, 162, 111, 0.1);
  padding: 2px 8px;
  border-radius: var(--radius-xs);
  margin-bottom: var(--space-2);
}

.timeline-role {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.timeline-entity {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  color: var(--concrete-light);
  margin-bottom: var(--space-3);
}

.timeline-desc {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 0;
}

/* ==========================================================================
   8. PROJECT DETAIL MODAL
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-6);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-fast), visibility var(--transition-fast);
}

.modal-overlay.open {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-sm);
  width: 100%;
  max-width: 840px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  position: relative;
  padding: var(--space-8);
  transform: scale(0.96);
  transition: transform var(--transition-fast);
}

.modal-overlay.open .modal-content {
  transform: scale(1);
}

.modal-close-btn {
  position: absolute;
  top: var(--space-6);
  right: var(--space-6);
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.modal-close-btn:hover {
  color: var(--text-primary);
  border-color: var(--accent-gold);
}

.modal-specs-table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--space-6) 0;
  font-size: var(--text-sm);
}

.modal-specs-table th,
.modal-specs-table td {
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border-subtle);
  text-align: left;
}

.modal-specs-table th {
  background-color: var(--bg-surface-elevated);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--accent-gold);
  width: 35%;
}

.modal-specs-table td {
  color: var(--text-secondary);
}

/* ==========================================================================
   9. CONTACT FORM & INQUIRY
   ========================================================================== */
.contact-form-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: var(--space-8);
}

.form-group {
  margin-bottom: var(--space-6);
}

.form-label {
  display: block;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--concrete-light);
  margin-bottom: var(--space-2);
}

.form-control {
  width: 100%;
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xs);
  padding: 0.85rem 1rem;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--text-primary);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-gold);
  box-shadow: 0 0 0 2px var(--accent-gold-glow);
}

.form-control::placeholder {
  color: var(--text-dim);
  font-size: var(--text-sm);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

.form-feedback {
  padding: var(--space-4);
  border-radius: var(--radius-xs);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  margin-top: var(--space-4);
  display: none;
}

.form-feedback.success {
  display: block;
  background-color: rgba(194, 162, 111, 0.12);
  border: 1px solid var(--accent-gold);
  color: var(--accent-gold-light);
}

.form-feedback.error {
  display: block;
  background-color: rgba(220, 53, 69, 0.12);
  border: 1px solid rgba(220, 53, 69, 0.4);
  color: #ff858d;
}

/* ==========================================================================
   10. CORPORATE FOOTER
   ========================================================================== */
.site-footer {
  background-color: #080A0D;
  border-top: 1px solid var(--border-subtle);
  padding: var(--space-16) 0 var(--space-8);
  margin-top: auto;
  position: relative;
  z-index: var(--z-base);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr 1.5fr;
  gap: var(--space-10);
  margin-bottom: var(--space-12);
}

.footer-brand-col {
  padding-right: var(--space-6);
}

.footer-title {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-bottom: var(--space-4);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-link {
  font-size: var(--text-sm);
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.footer-link:hover {
  color: var(--text-primary);
  padding-left: 2px;
}

.footer-bottom {
  border-top: 1px solid var(--border-subtle);
  padding-top: var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--text-dim);
}
