/* ══════════════════════════════════════════════════
   ATELIER MASSWERK — Global Styles
   ══════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;1,300;1,400&family=DM+Sans:wght@300;400;500&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --sand:        #F5F0E8;
  --sand-mid:    #EDE6D6;
  --sand-dark:   #D9CEBC;
  --charcoal:    #1A1A1A;
  --charcoal-mid:#2E2E2E;
  --warm-gray:   #6B6560;
  --light-gray:  #9B9590;
  --accent:      #8B6F47;
  --accent-light:#C9A87C;
  --accent-pale: #F0E6D3;
  --white:       #FFFFFF;
  --border:      rgba(26,26,26,0.1);
  --border-mid:  rgba(26,26,26,0.18);
  --nav-h:       76px;
  --r:           14px;
  --r-lg:        20px;
  --serif:       'Cormorant Garamond', Georgia, serif;
  --sans:        'DM Sans', system-ui, sans-serif;
  --shadow:      0 4px 32px rgba(0,0,0,0.07);
  --shadow-lg:   0 8px 48px rgba(0,0,0,0.12);
}

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

body {
  font-family: var(--sans);
  background: var(--white);
  color: var(--charcoal);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--sand); }
::-webkit-scrollbar-thumb { background: var(--sand-dark); border-radius: 3px; }

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

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

/* ── NAVIGATION ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 5vw;
  background: rgba(255,255,255,0.88);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}
.nav.scrolled { box-shadow: 0 2px 24px rgba(0,0,0,0.08); }

.nav-logo {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--charcoal);
  display: flex; align-items: baseline; gap: 0.15em;
}
.nav-logo .dot { color: var(--accent); font-size: 1.8rem; line-height: 0; margin-bottom: -4px; }

.nav-links {
  display: flex; align-items: center; gap: 0.25rem;
  list-style: none;
}
.nav-links a {
  display: inline-flex; align-items: center;
  padding: 0.4rem 0.9rem;
  font-size: 0.875rem; font-weight: 400; letter-spacing: 0.03em;
  color: var(--warm-gray); border-radius: 100px;
  transition: color 0.2s, background 0.2s;
}
.nav-links a:hover { color: var(--charcoal); background: var(--sand); }
.nav-links a.active { color: var(--charcoal); font-weight: 500; }
.nav-links .nav-cta {
  background: var(--charcoal); color: var(--white) !important;
  padding: 0.5rem 1.4rem; margin-left: 0.5rem;
  font-weight: 500 !important;
  transition: background 0.2s, transform 0.15s !important;
}
.nav-links .nav-cta:hover { background: var(--accent) !important; transform: translateY(-1px); }

.nav-burger {
  display: none; cursor: pointer; flex-direction: column; gap: 5px;
  background: none; border: none; padding: 4px;
}
.nav-burger span { display: block; width: 22px; height: 1.5px; background: var(--charcoal); transition: all 0.3s; }
.nav-burger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── MOBILE NAV ── */
@media (max-width: 860px) {
  .nav-links {
    display: none;
    position: fixed; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--white);
    padding: 1rem 5vw 2rem;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 12px 32px rgba(0,0,0,0.1);
  }
  .nav-links.open { display: flex; }
  .nav-links a {
    padding: 1rem 0; border-radius: 0;
    border-bottom: 1px solid var(--border);
    font-size: 1rem; color: var(--charcoal);
  }
  .nav-links .nav-cta {
    margin: 1.25rem 0 0; border-radius: 100px;
    text-align: center; justify-content: center;
    padding: 0.875rem !important;
  }
  .nav-burger { display: flex; }
}

/* ── PAGE WRAPPER ── */
.page-wrap { padding-top: var(--nav-h); min-height: 100vh; }

/* ── SECTION HELPERS ── */
.section { padding: 6rem 5vw; }
.section--sand { background: var(--sand); }
.section--dark { background: var(--charcoal); color: var(--white); }
.section--accent-pale { background: var(--accent-pale); }

.eyebrow {
  display: inline-block;
  font-size: 0.7rem; font-weight: 500; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 1rem;
}
.section--dark .eyebrow { color: var(--accent-light); }

.section-title {
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 300; margin-bottom: 1.25rem;
}
.section-sub {
  font-size: 1.0625rem; color: var(--warm-gray);
  font-weight: 300; max-width: 560px; margin-bottom: 3rem; line-height: 1.8;
}
.section--dark .section-sub { color: rgba(255,255,255,0.5); }

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.875rem 2rem; border-radius: 100px;
  font-family: var(--sans); font-size: 0.9375rem; font-weight: 500;
  border: none; cursor: pointer; text-decoration: none;
  transition: transform 0.2s, background 0.2s, box-shadow 0.2s;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--charcoal); color: var(--white);
  box-shadow: 0 4px 16px rgba(26,26,26,0.2);
}
.btn-primary:hover { background: var(--accent); box-shadow: 0 6px 24px rgba(139,111,71,0.35); }

.btn-outline {
  background: transparent; color: var(--charcoal);
  border: 1.5px solid var(--border-mid);
}
.btn-outline:hover { border-color: var(--charcoal); background: var(--sand); }

.btn-light {
  background: var(--white); color: var(--charcoal);
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}
.btn-light:hover { background: var(--sand); }

.btn-accent {
  background: var(--accent); color: var(--white);
  box-shadow: 0 4px 16px rgba(139,111,71,0.3);
}
.btn-accent:hover { background: #7a6040; }

.btn-sm { padding: 0.6rem 1.4rem; font-size: 0.875rem; }

.btn svg { flex-shrink: 0; }

/* ── CARDS ── */
.card {
  background: var(--white); border-radius: var(--r-lg);
  border: 1px solid var(--border); overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.card-img {
  width: 100%; aspect-ratio: 4/3;
  background: var(--sand-mid);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 0.5rem;
  color: var(--light-gray); font-size: 0.75rem;
  letter-spacing: 0.06em; text-align: center; padding: 1rem;
  font-family: var(--sans);
}
.card-img svg { opacity: 0.3; }

.card-body { padding: 1.5rem 1.75rem 2rem; }
.card-body h3 { font-size: 1.4rem; font-weight: 400; margin-bottom: 0.6rem; }
.card-body p { color: var(--warm-gray); font-size: 0.9375rem; font-weight: 300; line-height: 1.7; }

/* ── GRID LAYOUTS ── */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.grid-split { display: grid; grid-template-columns: 1fr 1fr; gap: 5vw; align-items: center; }

@media (max-width: 900px) {
  .grid-2, .grid-3, .grid-4, .grid-split { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .section { padding: 4rem 5vw; }
}

/* ── IMAGE PLACEHOLDER ── */
.img-box {
  background: var(--sand-mid); border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 0.75rem;
  color: var(--light-gray); font-size: 0.75rem; letter-spacing: 0.06em;
  text-align: center; padding: 2rem;
}
.img-box svg { opacity: 0.3; }

/* ── FORMS ── */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-full { grid-column: 1 / -1; }

.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-group label {
  font-size: 0.8125rem; font-weight: 500; letter-spacing: 0.04em;
  color: var(--charcoal);
}
.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.8rem 1.1rem;
  border: 1.5px solid var(--border-mid);
  border-radius: 10px;
  font-family: var(--sans); font-size: 0.9375rem; font-weight: 300;
  background: var(--white); color: var(--charcoal);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none; resize: vertical; appearance: none;
  -webkit-appearance: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(139,111,71,0.12);
}
.form-group select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236B6560' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}
.form-group textarea { min-height: 120px; }
.form-hint { font-size: 0.8rem; color: var(--light-gray); font-weight: 300; }
.form-error { display: none; font-size: 0.8rem; color: #c0392b; font-weight: 400; }
.form-group.has-error input,
.form-group.has-error select,
.form-group.has-error textarea { border-color: #c0392b; }
.form-group.has-error .form-error { display: block; }

.alert {
  display: none; padding: 1rem 1.25rem; border-radius: 10px;
  font-size: 0.9375rem; font-weight: 400; margin-bottom: 1rem;
}
.alert-success { background: #E8F5E9; color: #2E7D32; border: 1px solid #C8E6C9; }
.alert-error   { background: #FFEBEE; color: #C62828; border: 1px solid #FFCDD2; }
.alert.show    { display: flex; align-items: flex-start; gap: 0.75rem; }

/* ── BADGE ── */
.badge {
  display: inline-block;
  padding: 0.3rem 0.875rem; border-radius: 100px;
  font-size: 0.75rem; font-weight: 500; letter-spacing: 0.05em;
}
.badge-accent { background: var(--accent-pale); color: var(--accent); }
.badge-dark   { background: var(--charcoal); color: var(--white); }

/* ── DIVIDER ── */
.divider { border: none; border-top: 1px solid var(--border); margin: 3rem 0; }

/* ── FOOTER ── */
footer {
  background: var(--charcoal); color: rgba(255,255,255,0.6);
  padding: 5rem 5vw 2.5rem;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem; margin-bottom: 4rem;
}
.footer-logo {
  font-family: var(--serif); font-size: 1.5rem; font-weight: 400;
  color: var(--white); margin-bottom: 1rem; display: block;
}
.footer-desc {
  font-size: 0.875rem; line-height: 1.8; font-weight: 300; max-width: 280px;
  margin-bottom: 1.5rem;
}
.footer-social { display: flex; gap: 0.75rem; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.2);
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.6); transition: all 0.2s;
}
.footer-social a:hover { background: rgba(255,255,255,0.1); color: var(--white); }

.footer-col h4 {
  font-size: 0.7rem; font-weight: 500; letter-spacing: 0.14em;
  text-transform: uppercase; color: rgba(255,255,255,0.35);
  margin-bottom: 1.25rem;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 0.625rem; }
.footer-col a {
  color: rgba(255,255,255,0.6); font-size: 0.875rem; font-weight: 300;
  transition: color 0.2s; text-decoration: none;
}
.footer-col a:hover { color: var(--white); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1); padding-top: 2rem;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem;
}
.footer-bottom p { font-size: 0.8125rem; }
.footer-legal { display: flex; gap: 1.75rem; }
.footer-legal a { font-size: 0.8125rem; color: rgba(255,255,255,0.5); text-decoration: none; transition: color 0.2s; }
.footer-legal a:hover { color: var(--white); }

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}
@media (max-width: 500px) {
  .footer-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 1rem; }
}

/* ── LEGAL PAGES ── */
.legal-wrap { max-width: 780px; margin: 0 auto; padding: 4rem 5vw 6rem; }
.legal-wrap h1 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 300; margin-bottom: 0.5rem; }
.legal-meta { font-size: 0.875rem; color: var(--light-gray); margin-bottom: 3rem; }
.legal-wrap h2 { font-size: 1.25rem; font-weight: 400; margin: 2.5rem 0 0.875rem; color: var(--charcoal); }
.legal-wrap h3 { font-size: 1rem; font-weight: 500; margin: 1.5rem 0 0.5rem; font-family: var(--sans); }
.legal-wrap p, .legal-wrap li { font-size: 0.9375rem; color: var(--warm-gray); font-weight: 300; line-height: 1.85; margin-bottom: 0.75rem; }
.legal-wrap ul, .legal-wrap ol { padding-left: 1.5rem; margin-bottom: 1rem; }
.legal-wrap li { margin-bottom: 0.4rem; }
.legal-wrap a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.legal-wrap strong { font-weight: 500; color: var(--charcoal); }
.legal-wrap table { width: 100%; border-collapse: collapse; margin: 1.25rem 0; }
.legal-wrap th { text-align: left; font-size: 0.8rem; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase; color: var(--light-gray); padding: 0.5rem 0; border-bottom: 1px solid var(--border); }
.legal-wrap td { padding: 0.75rem 0; font-size: 0.9375rem; color: var(--warm-gray); font-weight: 300; border-bottom: 1px solid var(--border); vertical-align: top; }

/* ── COOKIE BANNER ── */
#cookie-banner {
  position: fixed; bottom: 1.5rem; left: 1.5rem; right: 1.5rem;
  max-width: 500px;
  background: var(--charcoal); color: var(--white);
  border-radius: var(--r-lg); padding: 1.5rem 1.75rem;
  box-shadow: 0 8px 40px rgba(0,0,0,0.25);
  z-index: 9999; display: none;
}
#cookie-banner p { font-size: 0.875rem; color: rgba(255,255,255,0.75); margin-bottom: 1rem; font-weight: 300; line-height: 1.6; }
#cookie-banner p a { color: var(--accent-light); text-decoration: underline; }
.cookie-btns { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.cookie-btns button {
  flex: 1; min-width: 100px;
  padding: 0.65rem 1rem; border-radius: 100px;
  font-family: var(--sans); font-size: 0.875rem; font-weight: 500;
  cursor: pointer; border: none; transition: all 0.2s;
}
.cookie-accept { background: var(--accent); color: var(--white); }
.cookie-accept:hover { background: #7a6040; }
.cookie-decline { background: rgba(255,255,255,0.1); color: var(--white); }
.cookie-decline:hover { background: rgba(255,255,255,0.2); }

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp 0.6s ease forwards; }
.fade-up-d1 { animation-delay: 0.1s; opacity: 0; }
.fade-up-d2 { animation-delay: 0.2s; opacity: 0; }
.fade-up-d3 { animation-delay: 0.3s; opacity: 0; }
.fade-up-d4 { animation-delay: 0.4s; opacity: 0; }

/* ── SCROLL REVEAL ── */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.visible { opacity: 1; transform: none; }
