/* ==========================================================================
   LAYZE.XYZ — Clean Editorial Dark Stylesheet
   Designed for Alfaro (Finance & Operations / Digital Builder)
   ========================================================================== */

/* --- Custom Properties / Theme Variables --- */
:root {
  --bg-base: #090a0d;
  --bg-surface: #121318;
  --bg-surface-hover: #181920;
  --bg-elevated: #1d1e26;
  
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-light: rgba(255, 255, 255, 0.12);
  --border-hover: rgba(255, 255, 255, 0.22);
  
  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-dim: #6b7280;
  
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-blue: #3b82f6;
  
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', ui-monospace, monospace;
  
  --max-w: 1040px;
  --radius-lg: 14px;
  --radius-md: 10px;
  --radius-sm: 6px;
  --transition: all 0.2s ease-in-out;
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  background-color: var(--bg-base);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

::selection {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

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

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Navigation Header --- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(9, 10, 13, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.brand-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
}

.brand-text {
  font-family: var(--font-mono);
  font-size: 1.05rem;
}

.brand-sub {
  font-size: 0.75rem;
  color: var(--text-dim);
  font-family: var(--font-sans);
  font-weight: 400;
  border-left: 1px solid var(--border-subtle);
  padding-left: 10px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-links a {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
}

.nav-links a:hover {
  color: var(--text-main);
  background: var(--bg-surface);
}

.btn-header-cta {
  margin-left: 12px;
  font-size: 0.78rem !important;
  font-weight: 600 !important;
  background: var(--text-main) !important;
  color: var(--bg-base) !important;
  border-radius: 20px !important;
  padding: 6px 14px !important;
}

.btn-header-cta:hover {
  background: #ffffff !important;
}

/* Mobile Menu Toggle */
.mobile-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 6px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* --- Hero Section --- */
.hero {
  padding: 80px 0 60px;
  border-bottom: 1px solid var(--border-subtle);
  position: relative;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  margin-bottom: 24px;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-emerald);
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-bottom: 16px;
}

.hero-tagline {
  font-size: clamp(1.25rem, 3vw, 1.8rem);
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.35;
  margin-bottom: 20px;
}

.hero-tagline strong {
  color: var(--text-main);
  font-weight: 600;
}

.hero-desc {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 680px;
  line-height: 1.65;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--text-main);
  color: var(--bg-base);
}

.btn-primary:hover {
  background: #ffffff;
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--text-main);
  border: 1px solid var(--border-light);
}

.btn-secondary:hover {
  border-color: var(--border-hover);
  background: var(--bg-surface-hover);
}

/* --- Section Layouts --- */
.section {
  padding: 80px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.section-head {
  margin-bottom: 40px;
}

.section-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent-emerald);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 6px;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-main);
  margin-bottom: 10px;
}

.section-desc {
  font-size: 0.92rem;
  color: var(--text-muted);
  max-width: 600px;
}

/* --- Selected Work Cards --- */
.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
}

.work-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.work-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
}

.work-card-media {
  width: 100%;
  height: 220px;
  background: #0d0e13;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.work-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.work-card-media img.contain {
  object-fit: contain;
  padding: 16px;
}

.work-card:hover .work-card-media img {
  transform: scale(1.03);
}

.media-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #151720 0%, #0d0e13 100%);
  color: var(--text-dim);
  font-size: 0.8rem;
  font-family: var(--font-mono);
}

.media-placeholder svg {
  width: 32px;
  height: 32px;
  opacity: 0.4;
}

.work-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
}

.card-pill {
  padding: 2px 8px;
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-muted);
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-main);
}

.card-text {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 18px;
  flex-grow: 1;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  padding-top: 14px;
  font-size: 0.78rem;
}

.card-tags {
  color: var(--text-dim);
  font-family: var(--font-mono);
}

.card-link {
  font-weight: 600;
  color: var(--text-main);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.card-link:hover {
  text-decoration: underline;
}

/* --- The Lab & Interactive Dashboard --- */
.lab-featured {
  background: linear-gradient(180deg, var(--bg-surface) 0%, rgba(18, 19, 24, 0.6) 100%);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 36px;
}

.lab-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

/* Dashboard Mockup Container */
.dashboard-mockup {
  background: var(--bg-base);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.dash-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-subtle);
  font-size: 0.78rem;
  font-family: var(--font-mono);
}

.dash-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
  padding: 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.metric-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 14px;
}

.metric-label {
  font-size: 0.7rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
  text-transform: uppercase;
}

.metric-val {
  font-size: 1.15rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--text-main);
  margin: 4px 0;
}

.metric-sub {
  font-size: 0.7rem;
  color: var(--accent-emerald);
  font-family: var(--font-mono);
}

.dash-table-wrap {
  padding: 20px;
  overflow-x: auto;
}

.dash-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.dash-table th {
  text-align: left;
  padding: 10px;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-weight: 500;
  border-bottom: 1px solid var(--border-subtle);
}

.dash-table td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--border-subtle);
}

.badge-status {
  padding: 3px 8px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
}

.badge-pending {
  background: rgba(245, 158, 11, 0.1);
  color: var(--accent-amber);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.badge-approved {
  background: rgba(16, 185, 129, 0.1);
  color: var(--accent-emerald);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.btn-approve {
  background: var(--text-main);
  color: var(--bg-base);
  border: none;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: var(--transition);
}

.btn-approve:hover {
  background: #ffffff;
}

.btn-approve:disabled {
  opacity: 0.4;
  cursor: default;
}

/* --- About & Timeline --- */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.timeline-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 24px;
}

.timeline-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.timeline-company {
  font-size: 1.15rem;
  font-weight: 700;
}

.timeline-role {
  color: var(--accent-emerald);
  font-size: 0.85rem;
  font-family: var(--font-mono);
}

.timeline-period {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
}

.timeline-list {
  padding-left: 20px;
  font-size: 0.86rem;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Capability Table */
.cap-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  margin-top: 24px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.cap-table th {
  background: var(--bg-elevated);
  padding: 12px 16px;
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
}

.cap-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.cap-table tr:hover td {
  background: var(--bg-surface);
}

/* --- Notes List --- */
.notes-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.note-card {
  display: block;
  padding: 22px 24px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.note-card:hover {
  border-color: var(--border-hover);
  transform: translateX(4px);
}

.note-meta {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
  margin-bottom: 6px;
}

.note-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 6px;
}

.note-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* --- Contact & Footer --- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 40px;
}

.contact-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 16px;
}

.contact-card label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  text-transform: uppercase;
  display: block;
  margin-bottom: 4px;
}

.contact-card a {
  font-size: 0.95rem;
  font-weight: 600;
}

.contact-form {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
  text-transform: uppercase;
}

.form-control {
  background: var(--bg-base);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-family: var(--font-sans);
  outline: none;
  transition: var(--transition);
}

.form-control:focus {
  border-color: #ffffff;
}

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

.footer {
  padding: 60px 0 40px;
  border-top: 1px solid var(--border-subtle);
  background: rgba(9, 10, 13, 0.7);
  font-size: 0.8rem;
  color: var(--text-dim);
}

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

/* --- Responsive Adjustments --- */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .mobile-toggle {
    display: block;
  }
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .footer-content {
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
  }
  .footer-content > div:last-child {
    text-align: left !important;
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .btn {
    width: 100%;
  }
}
