:root {
  --bg: #f6f1ea;
  --bg-soft: #efe7dc;
  --text: #171717;
  --muted: #6d655d;
  --line: rgba(23, 23, 23, 0.12);
  --white: #ffffff;
  --dark: #111111;
  --accent: #9b6038;
  --header-bg: rgba(246, 241, 234, 0.88);
  --panel-bg: #ffffff;
}

body.dark-mode {
  --bg: #111111;
  --bg-soft: #1a1a1a;
  --text: #f6f1ea;
  --muted: #a0a0a0;
  --line: rgba(246, 241, 234, 0.12);
  --white: #171717;
  --dark: #f6f1ea;
  --header-bg: rgba(17, 17, 17, 0.88);
  --panel-bg: #1e1e1e;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  word-break: keep-all;
  transition: background-color 0.3s, color 0.3s;
}

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

img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.container {
  width: min(1400px, calc(100% - 48px));
  margin: 0 auto;
}

/* 움직이는 상단 바 */
.announcement {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: #111;
  color: #fff;
  overflow: hidden;
  white-space: nowrap;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  z-index: 1100;
}

.announcement-track {
  display: inline-block;
  padding: 10px 0;
  min-width: 200%;
  animation: marquee 22s linear infinite;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.header {
  position: fixed;
  top: 41px;
  left: 0;
  width: 100%;
  background: var(--header-bg);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  z-index: 1000;
  transition: background-color 0.3s;
}

.header-inner {
  width: min(1400px, calc(100% - 48px));
  height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}

.nav a {
  font-size: 14px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  transition: 0.2s;
}

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

/* 테마 토글 버튼 수정 */
.theme-toggle {
  background: none;
  border: 1px solid var(--line);
  color: var(--text);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 50%;
  transition: all 0.3s ease;
  z-index: 1100;
  position: relative;
  overflow: hidden;
}

.theme-toggle:hover {
  background: var(--text);
  color: var(--bg);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
}

.sun-icon { display: none; }
.moon-icon { display: block; }

body.dark-mode .sun-icon { display: block; }
body.dark-mode .moon-icon { display: none; }

/* 문의 폼 스타일 */
.contact-wrapper {
  max-width: 800px;
  margin: 0 auto;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

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

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-group label {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 14px 18px;
  background: var(--panel-bg);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  border-radius: 0;
  transition: border-color 0.2s, background-color 0.2s;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--text);
}

.contact-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
}

.submit-btn {
  width: 100%;
  margin-top: 10px;
  height: 56px;
  font-size: 16px;
  cursor: pointer;
}

@media (max-width: 720px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.hero {
  min-height: 100vh;
  display: flex;
  align-items: flex-end;
  padding: 181px 0 56px;
  color: #ffffff;
  background:
    linear-gradient(90deg, rgba(0,0,0,0.58) 0%, rgba(0,0,0,0.25) 55%, rgba(0,0,0,0.12) 100%),
    url("https://images.unsplash.com/photo-1495474472287-4d71bcdd2085?auto=format&fit=crop&w=1800&q=80") center center / cover no-repeat;
}

.eyebrow {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: 18px;
  opacity: 0.9;
}

.hero h1 {
  font-size: clamp(48px, 9vw, 116px);
  line-height: 0.95;
  letter-spacing: -0.05em;
  font-weight: 800;
  max-width: 980px;
}

.hero p {
  margin-top: 24px;
  max-width: 640px;
  font-size: 18px;
  color: rgba(255,255,255,0.86);
}

.hero-buttons {
  margin-top: 34px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 22px;
  min-width: 160px;
  border: 1px solid rgba(255,255,255,0.28);
  color: #ffffff;
  font-weight: 700;
  transition: 0.25s;
}

.btn:hover {
  background: #ffffff;
  color: #111111;
}

.btn.fill {
  background: #ffffff;
  color: #111111;
}

.btn.fill:hover {
  background: transparent;
  color: #ffffff;
}

section {
  padding: 120px 0;
  border-bottom: 1px solid var(--line);
}

.section-head {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 40px;
  align-items: end;
  margin-bottom: 56px;
}

.section-label {
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 18px;
}

.section-title {
  font-size: clamp(34px, 5vw, 72px);
  line-height: 1;
  letter-spacing: -0.04em;
  font-weight: 800;
}

.section-desc {
  font-size: 17px;
  color: var(--muted);
  max-width: 520px;
  justify-self: end;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 24px;
}

.panel {
  background: var(--panel-bg);
  border: 1px solid var(--line);
  min-height: 430px;
  transition: background-color 0.3s;
}

.panel-text {
  padding: 42px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.panel-text h3 {
  font-size: 38px;
  line-height: 1.06;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
}

.panel-text p {
  color: var(--muted);
  font-size: 16px;
  max-width: 560px;
}

.stats {
  margin-top: 34px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.stats div strong {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
  color: var(--text);
}

.stats div span {
  font-size: 14px;
  color: var(--muted);
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.card {
  background: var(--panel-bg);
  border: 1px solid var(--line);
  min-height: 520px;
  display: flex;
  flex-direction: column;
  transition: background-color 0.3s;
}

.card-image {
  height: 300px;
  overflow: hidden;
}

.card-body {
  padding: 28px;
}

.card-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-bottom: 12px;
}

.card h3 {
  font-size: 28px;
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin-bottom: 14px;
}

.card p {
  font-size: 15px;
  color: var(--muted);
}

.dark-section {
  background: #111111;
  color: #ffffff;
}

.dark-section .section-label,
.dark-section .section-desc {
  color: rgba(255,255,255,0.68);
}

.story-grid {
  display: grid;
  grid-template-columns: 1fr 0.9fr;
  gap: 24px;
}

.story-box {
  min-height: 430px;
  border: 1px solid rgba(255,255,255,0.14);
  padding: 42px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: rgba(255,255,255,0.03);
}

.story-box h3 {
  font-size: clamp(34px, 4.5vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.04em;
  max-width: 720px;
}

.story-box p {
  color: rgba(255,255,255,0.7);
  max-width: 520px;
}

.story-image {
  min-height: 430px;
  border: 1px solid rgba(255,255,255,0.14);
  overflow: hidden;
}

.visit-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 24px;
}

.visit-card {
  background: var(--panel-bg);
  border: 1px solid var(--line);
  padding: 38px;
  min-height: 420px;
  transition: background-color 0.3s;
}

.visit-card h3 {
  font-size: 42px;
  line-height: 1.02;
  letter-spacing: -0.04em;
  margin-bottom: 22px;
}

.visit-item {
  border-top: 1px solid var(--line);
  padding: 18px 0;
}

.visit-item strong {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 8px;
}

.visit-item span {
  font-size: 15px;
  color: var(--muted);
}

.visit-image {
  min-height: 420px;
  overflow: hidden;
  border: 1px solid var(--line);
  position: relative;
}

.visit-image::after {
  content: "BRICKERS COFFEE";
  position: absolute;
  left: 24px;
  bottom: 24px;
  background: rgba(255,255,255,0.92);
  color: #111111;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.footer {
  background: var(--bg-soft);
  padding: 46px 0 52px;
  transition: background-color 0.3s;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: end;
}

.footer-logo {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 10px;
}

.footer p {
  font-size: 14px;
  color: var(--muted);
}

.footer-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 22px;
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

@media (max-width: 1080px) {
  .section-head, .about-grid, .story-grid, .visit-grid, .cards {
    grid-template-columns: 1fr;
  }
  .section-desc { justify-self: start; }
}

@media (max-width: 720px) {
  .header {
    top: 41px;
  }
  .header-inner {
    height: auto;
    padding: 18px 0;
    flex-direction: row; /* 모바일에서도 로고와 우측 영역을 가로로 배치 */
    justify-content: space-between;
    align-items: center;
  }
  .header-right {
    gap: 12px;
  }
  .nav {
    display: none; /* 모바일에서 메뉴는 일단 숨김 (필요시 햄버거 메뉴 구현) */
  }
  .container { width: min(100% - 28px, 1400px); }
  .hero { padding: 201px 0 44px; }
  .hero p { font-size: 16px; }
  section { padding: 86px 0; }
  .panel-text, .story-box, .visit-card { padding: 28px; }
  .stats { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
}
