/* =====================================================
   FUNDACJA "VEXILLA REGIS" — Global Stylesheet
   ===================================================== */

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

:root {
  --gold:       #9B7D3A;
  --gold-light: #C4A35A;
  --gold-pale:  #F5EDD8;
  --dark:       #1A1510;
  --dark-mid:   #2C2318;
  --charcoal:   #3E3530;
  --mid:        #6B5D50;
  --light:      #F8F4EE;
  --white:      #FFFFFF;
  --border:     #D4C4A8;

  --font-head: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Lato', Arial, sans-serif;

  --max-width: 1140px;
  --nav-height: 80px;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--light);
  color: var(--charcoal);
  line-height: 1.7;
  font-size: 16px;
}

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

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-light); }

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

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--dark);
  line-height: 1.25;
  font-weight: 600;
}

h1 { font-size: clamp(2.4rem, 5vw, 4rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.8rem); }
h4 { font-size: 1.15rem; }

p { margin-bottom: 1rem; }

.section-label {
  display: block;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}

.section-title {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  color: var(--dark);
  margin-bottom: 1.2rem;
  line-height: 1.2;
}

.section-intro {
  font-size: 1.05rem;
  color: var(--mid);
  max-width: 620px;
  line-height: 1.8;
}

/* --- Ornamental Divider --- */
.ornament {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 1.5rem 0;
}
.ornament::before,
.ornament::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.ornament span {
  color: var(--gold);
  font-size: 1.2rem;
  font-family: var(--font-head);
}

/* =====================================================
   HEADER / NAVIGATION
   ===================================================== */

header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  background: var(--dark);
  border-bottom: 1px solid rgba(155, 125, 58, 0.35);
  display: flex;
  align-items: center;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.nav-brand {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}

.nav-brand-name {
  font-family: var(--font-head);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--gold-light);
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.nav-brand-sub {
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(196, 163, 90, 0.6);
  font-family: var(--font-body);
}

nav ul {
  list-style: none;
  display: flex;
  gap: 6px;
  align-items: center;
}

nav ul li a {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.75);
  padding: 6px 12px;
  border-radius: 2px;
  transition: color 0.2s, background 0.2s;
}

nav ul li a:hover,
nav ul li a.active {
  color: var(--gold-light);
  background: rgba(155,125,58,0.12);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--gold-light);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* =====================================================
   PAGE WRAPPER — offset for fixed header
   ===================================================== */
.page-content {
  padding-top: var(--nav-height);
}

/* =====================================================
   HERO SECTION
   ===================================================== */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 88vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(20,15,8,0.72) 0%, rgba(20,15,8,0.55) 60%, rgba(20,15,8,0.8) 100%);
  z-index: 1;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 60px 24px;
  max-width: 860px;
}

.hero-badge {
  display: inline-block;
  border: 1px solid rgba(196,163,90,0.5);
  color: var(--gold-light);
  font-size: 0.68rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  padding: 6px 20px;
  margin-bottom: 28px;
  font-family: var(--font-body);
  font-weight: 700;
}

.hero-title {
  font-family: var(--font-head);
  font-size: clamp(2.6rem, 6vw, 5rem);
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 12px;
  text-shadow: 0 2px 18px rgba(0,0,0,0.5);
  font-weight: 700;
  font-style: italic;
}

.hero-subtitle {
  font-family: var(--font-head);
  font-size: clamp(1rem, 2.5vw, 1.5rem);
  color: rgba(255,255,255,0.85);
  margin-bottom: 28px;
  letter-spacing: 0.06em;
}

.hero-desc {
  font-size: clamp(0.9rem, 1.8vw, 1.05rem);
  color: rgba(255,255,255,0.75);
  max-width: 620px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- Buttons --- */
.btn-primary {
  display: inline-block;
  background: var(--gold);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 14px 34px;
  border: 2px solid var(--gold);
  transition: background 0.25s, color 0.25s;
}
.btn-primary:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  color: var(--white);
}

.btn-outline {
  display: inline-block;
  background: transparent;
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 14px 34px;
  border: 2px solid rgba(255,255,255,0.5);
  transition: border-color 0.25s, color 0.25s;
}
.btn-outline:hover {
  border-color: var(--gold-light);
  color: var(--gold-light);
}

/* =====================================================
   SECTION PADDING
   ===================================================== */
.section-pad {
  padding: 90px 0;
}
.section-pad-sm {
  padding: 60px 0;
}

/* =====================================================
   INTRO BAND (Home Page)
   ===================================================== */
.intro-band {
  background: var(--dark);
  padding: 60px 0;
}

.intro-band-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
}

.intro-pillar {
  padding: 40px 32px;
  border-right: 1px solid rgba(155,125,58,0.2);
  text-align: center;
}
.intro-pillar:last-child { border-right: none; }

.intro-pillar-icon {
  font-size: 2rem;
  color: var(--gold);
  margin-bottom: 16px;
  font-family: var(--font-head);
  font-style: italic;
}

.intro-pillar h3 {
  color: var(--gold-light);
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.intro-pillar p {
  color: rgba(255,255,255,0.65);
  font-size: 0.92rem;
  margin-bottom: 0;
  line-height: 1.7;
}

/* =====================================================
   TWO-COLUMN SPLIT
   ===================================================== */
.split-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.split-section.reverse .split-image { order: 2; }
.split-section.reverse .split-text  { order: 1; }

.split-image img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  border: 4px solid var(--border);
}

/* =====================================================
   QUOTE / PULL QUOTE
   ===================================================== */
.pull-quote {
  background: var(--dark-mid);
  padding: 70px 0;
  text-align: center;
}

.pull-quote blockquote {
  font-family: var(--font-head);
  font-style: italic;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  color: var(--gold-pale);
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.5;
}

.pull-quote blockquote::before { content: '\201C'; }
.pull-quote blockquote::after  { content: '\201D'; }

.pull-quote cite {
  display: block;
  margin-top: 20px;
  font-size: 0.82rem;
  color: var(--gold);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-style: normal;
  font-family: var(--font-body);
  font-weight: 700;
}

/* =====================================================
   CARDS GRID
   ===================================================== */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 36px 28px;
  transition: box-shadow 0.25s, transform 0.25s;
}
.card:hover {
  box-shadow: 0 8px 32px rgba(155,125,58,0.12);
  transform: translateY(-4px);
}

.card-icon {
  width: 48px;
  height: 3px;
  background: var(--gold);
  margin-bottom: 22px;
}

.card h3 {
  font-size: 1.25rem;
  margin-bottom: 12px;
  color: var(--dark);
}

.card p {
  font-size: 0.94rem;
  color: var(--mid);
  line-height: 1.75;
  margin-bottom: 0;
}

/* =====================================================
   ACTIVITIES PAGE
   ===================================================== */
.activity-item {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 60px;
  align-items: start;
  padding: 60px 0;
  border-bottom: 1px solid var(--border);
}
.activity-item:last-child { border-bottom: none; }

.activity-item img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border: 3px solid var(--border);
}

.activity-number {
  font-family: var(--font-head);
  font-size: 4rem;
  color: var(--gold-pale);
  line-height: 1;
  font-weight: 700;
  margin-bottom: 4px;
}

.activity-tag {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 700;
  margin-bottom: 10px;
}

.activity-item h3 {
  font-size: 1.6rem;
  margin-bottom: 14px;
}

.activity-item p {
  color: var(--mid);
  font-size: 0.96rem;
  line-height: 1.8;
}

/* =====================================================
   GOALS PAGE
   ===================================================== */
.goals-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.goal-item {
  background: var(--white);
  border-left: 4px solid var(--gold);
  padding: 28px 28px 28px 28px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.goal-num {
  font-family: var(--font-head);
  font-size: 2.2rem;
  color: var(--gold-light);
  line-height: 1;
  font-weight: 700;
  flex-shrink: 0;
  min-width: 40px;
}

.goal-item h4 {
  font-size: 1.05rem;
  color: var(--dark);
  margin-bottom: 8px;
  font-family: var(--font-head);
  font-size: 1.2rem;
}

.goal-item p {
  font-size: 0.92rem;
  color: var(--mid);
  margin-bottom: 0;
  line-height: 1.7;
}

/* =====================================================
   MISSION PAGE — VALUES
   ===================================================== */
.values-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2px;
  background: var(--border);
}

.value-cell {
  background: var(--white);
  padding: 44px 36px;
}

.value-cell h3 {
  font-size: 1.4rem;
  color: var(--dark);
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--gold);
  display: inline-block;
}

.value-cell p {
  color: var(--mid);
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 0;
}

/* =====================================================
   PAGE BANNER (inner pages)
   ===================================================== */
.page-banner {
  position: relative;
  height: 340px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.page-banner-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}

.page-banner-overlay {
  position: absolute;
  inset: 0;
  background: rgba(20,15,8,0.7);
  z-index: 1;
  pointer-events: none;
}

.page-banner-content {
  position: relative;
  z-index: 2;
  color: var(--white);
}

.page-banner-content h1 {
  color: var(--white);
  font-size: clamp(2rem, 5vw, 3.5rem);
  text-shadow: 0 2px 16px rgba(0,0,0,0.5);
}

.page-banner-content .section-label {
  color: var(--gold-light);
  margin-bottom: 10px;
}

/* =====================================================
   CONTACT PAGE
   ===================================================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 70px;
  align-items: start;
}

.contact-info h3 {
  font-size: 1.4rem;
  margin-bottom: 20px;
  color: var(--dark);
}

.contact-detail {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 36px;
}

.contact-detail-item {
  border-bottom: 1px solid var(--border);
  padding-bottom: 16px;
}

.contact-detail-item label {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 700;
  margin-bottom: 4px;
}

.contact-detail-item span {
  font-size: 0.95rem;
  color: var(--charcoal);
  line-height: 1.6;
}

.legal-box {
  background: var(--dark);
  padding: 24px;
  margin-top: 28px;
}

.legal-box h4 {
  color: var(--gold-light);
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 14px;
  font-family: var(--font-body);
  font-weight: 700;
}

.legal-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.65);
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.legal-row:last-child { border-bottom: none; }
.legal-row span:first-child { color: var(--gold-light); font-weight: 700; }

/* --- Contact Form --- */
.contact-form {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 44px;
}

.contact-form h3 {
  font-size: 1.6rem;
  margin-bottom: 28px;
  color: var(--dark);
}

.form-group {
  margin-bottom: 20px;
}

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

.form-group label {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--charcoal);
  margin-bottom: 6px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border);
  background: var(--light);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--dark);
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--gold);
}

.form-group textarea {
  resize: vertical;
  min-height: 130px;
}

.btn-submit {
  width: 100%;
  background: var(--gold);
  color: var(--white);
  border: none;
  padding: 15px 24px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.25s;
  font-family: var(--font-body);
}
.btn-submit:hover { background: var(--gold-light); }

#formStatus p { font-size: 0.95rem; margin: 0; }

/* =====================================================
   FOOTER
   ===================================================== */
footer {
  background: var(--dark);
  padding: 60px 0 30px;
  border-top: 1px solid rgba(155,125,58,0.3);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 50px;
  margin-bottom: 50px;
}

.footer-brand-name {
  font-family: var(--font-head);
  font-size: 1.2rem;
  color: var(--gold-light);
  font-weight: 700;
  margin-bottom: 10px;
  font-style: italic;
}

.footer-brand p {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.5);
  line-height: 1.75;
  margin-bottom: 0;
}

.footer-col h4 {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 700;
  font-family: var(--font-body);
  margin-bottom: 18px;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 10px;
}

.footer-col ul li a {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.55);
  transition: color 0.2s;
}
.footer-col ul li a:hover { color: var(--gold-light); }

.footer-col address {
  font-style: normal;
  font-size: 0.88rem;
  color: rgba(255,255,255,0.55);
  line-height: 1.9;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-bottom p {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.35);
  margin: 0;
}

/* =====================================================
   BREADCRUMB
   ===================================================== */
.breadcrumb {
  background: var(--gold-pale);
  padding: 12px 0;
  font-size: 0.8rem;
  color: var(--mid);
  border-bottom: 1px solid var(--border);
}
.breadcrumb a { color: var(--gold); }
.breadcrumb span { margin: 0 8px; }

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 1024px) {
  .split-section { grid-template-columns: 1fr; gap: 40px; }
  .split-section.reverse .split-image { order: 0; }
  .split-section.reverse .split-text  { order: 0; }
  .split-image img { height: 320px; }
  .cards-grid { grid-template-columns: 1fr 1fr; }
  .intro-band-grid { grid-template-columns: 1fr; }
  .intro-pillar { border-right: none; border-bottom: 1px solid rgba(155,125,58,0.2); }
  .intro-pillar:last-child { border-bottom: none; }
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
}

@media (max-width: 768px) {
  .nav-toggle { display: flex; }

  nav ul {
    display: none;
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: var(--dark);
    flex-direction: column;
    padding: 20px 24px 30px;
    border-bottom: 1px solid rgba(155,125,58,0.3);
    gap: 4px;
    z-index: 999;
  }
  nav ul.open { display: flex; }
  nav ul li a { font-size: 0.85rem; padding: 10px 16px; display: block; }

  .cards-grid { grid-template-columns: 1fr; }
  .goals-list { grid-template-columns: 1fr; }
  .values-grid { grid-template-columns: 1fr; }
  .activity-item { grid-template-columns: 1fr; gap: 24px; }
  .activity-item img { height: 220px; }
  .form-row { grid-template-columns: 1fr; }
  .contact-form { padding: 28px 20px; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .section-pad { padding: 60px 0; }
  .hero { min-height: 75vh; }
}

@media (max-width: 480px) {
  .hero-badge { font-size: 0.6rem; letter-spacing: 0.15em; }
  .hero-actions { flex-direction: column; align-items: center; }
  .page-banner { height: 260px; }
}
