/* ============================================
   Schülerbücherei BS Rohrbach – Stylesheet
   Anlehnung an bs-rohrbach.ac.at
   ============================================ */

:root {
  --accent:      #ba9117;
  --accent-dark: #9a7710;
  --accent-light:#f5ecc7;
  --dark:        #1e2229;
  --gray-dark:   #3a3f47;
  --gray-mid:    #6b7280;
  --gray-light:  #f4f5f7;
  --white:       #ffffff;
  --border:      #e0e2e6;
  --font:        'Segoe UI', Arial, sans-serif;
  --shadow:      0 2px 10px rgba(0,0,0,.10);
  --radius:      6px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--dark);
  background: var(--white);
  font-size: 16px;
  line-height: 1.65;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); text-decoration: underline; }

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

/* ── Utility ── */
.container { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.section { padding: 64px 0; }
.section--gray { background: var(--gray-light); }
.text-center { text-align: center; }

.btn {
  display: inline-block;
  padding: 10px 26px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background .2s, color .2s, transform .15s;
  border: none;
}
.btn--primary {
  background: var(--accent);
  color: var(--white);
}
.btn--primary:hover {
  background: var(--accent-dark);
  color: var(--white);
  text-decoration: none;
  transform: translateY(-1px);
}
.btn--outline {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}
.btn--outline:hover {
  background: var(--accent);
  color: var(--white);
  text-decoration: none;
}

/* ── Section headings ── */
.section-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
}
.section-title span { color: var(--accent); }
.section-subtitle {
  color: var(--gray-mid);
  margin-bottom: 40px;
  font-size: 1.05rem;
}
.divider {
  width: 56px; height: 4px;
  background: var(--accent);
  border-radius: 2px;
  margin: 12px 0 36px;
}
.divider--center { margin-left: auto; margin-right: auto; }

/* ============================================
   HEADER / NAVIGATION
   ============================================ */
.site-header {
  background: var(--white);
  border-bottom: 3px solid var(--accent);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--dark);
}
.logo:hover { text-decoration: none; color: var(--dark); }
.logo__icon {
  width: 48px; height: 48px;
  background: var(--accent);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem;
}
.logo__text { display: flex; flex-direction: column; }
.logo__title { font-size: 1.05rem; font-weight: 700; line-height: 1.2; }
.logo__subtitle { font-size: 0.75rem; color: var(--gray-mid); letter-spacing: .04em; text-transform: uppercase; }

/* Primary nav */
.main-nav ul { list-style: none; display: flex; gap: 4px; }
.main-nav a {
  display: block;
  padding: 8px 14px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--gray-dark);
  border-radius: var(--radius);
  transition: background .18s, color .18s;
}
.main-nav a:hover,
.main-nav a.active {
  background: var(--accent-light);
  color: var(--accent-dark);
  text-decoration: none;
}
.main-nav a.active { font-weight: 700; }

/* Burger */
.nav-toggle {
  display: none;
  flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 6px;
}
.nav-toggle span {
  display: block; width: 26px; height: 3px;
  background: var(--dark); border-radius: 2px;
  transition: all .25s;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  background: linear-gradient(135deg, var(--dark) 0%, #2d3442 60%, #3a4052 100%);
  color: var(--white);
  padding: 96px 0 80px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 40px,
    rgba(186,145,23,.04) 40px,
    rgba(186,145,23,.04) 80px
  );
}
.hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 48px;
  align-items: center;
}
.hero__badge {
  display: inline-block;
  background: var(--accent);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 20px;
  margin-bottom: 18px;
}
.hero__title {
  font-size: 2.6rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 18px;
}
.hero__title em { color: var(--accent); font-style: normal; }
.hero__text {
  font-size: 1.1rem;
  color: rgba(255,255,255,.82);
  margin-bottom: 32px;
  max-width: 520px;
}
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; }

.hero__card {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(186,145,23,.35);
  border-radius: 12px;
  padding: 28px;
  backdrop-filter: blur(4px);
}
.hero__card h3 {
  color: var(--accent);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 16px;
}
.hours-list { list-style: none; }
.hours-list li {
  display: flex; justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,.1);
  font-size: 0.9rem;
  color: rgba(255,255,255,.9);
}
.hours-list li:last-child { border-bottom: none; }
.hours-list .day { color: rgba(255,255,255,.6); }

/* ============================================
   CARDS
   ============================================ */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: box-shadow .2s, transform .2s;
}
.card:hover {
  box-shadow: 0 6px 24px rgba(0,0,0,.13);
  transform: translateY(-3px);
}
.card__icon {
  height: 140px;
  display: flex; align-items: center; justify-content: center;
  font-size: 3.5rem;
  background: var(--accent-light);
}
.card__body { padding: 22px; }
.card__title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--dark);
}
.card__text { color: var(--gray-mid); font-size: 0.92rem; margin-bottom: 16px; }
.card__link {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--accent);
  display: inline-flex; align-items: center; gap: 4px;
}
.card__link::after { content: '→'; transition: transform .2s; }
.card__link:hover::after { transform: translateX(4px); }
.card__link:hover { text-decoration: none; }

/* ============================================
   CATEGORIES (Bücherregale)
   ============================================ */
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 16px;
}
.category-item {
  background: var(--white);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 12px;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s;
}
.category-item:hover {
  border-color: var(--accent);
  background: var(--accent-light);
  transform: translateY(-2px);
}
.category-item__icon { font-size: 2.2rem; margin-bottom: 8px; }
.category-item__label { font-size: 0.88rem; font-weight: 600; color: var(--gray-dark); }

/* ============================================
   STATS BAR
   ============================================ */
.stats-bar {
  background: var(--accent);
  color: var(--white);
  padding: 32px 0;
}
.stats-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  text-align: center;
}
.stat__number {
  font-size: 2.2rem;
  font-weight: 800;
  display: block;
}
.stat__label {
  font-size: 0.85rem;
  opacity: .85;
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ============================================
   RULES / INFO BOXES
   ============================================ */
.info-box {
  background: var(--accent-light);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 24px;
  margin-bottom: 16px;
}
.info-box__title {
  font-weight: 700;
  color: var(--accent-dark);
  margin-bottom: 6px;
}
.info-box p { font-size: 0.92rem; color: var(--gray-dark); }

/* Step list */
.step-list { list-style: none; counter-reset: steps; }
.step-list li {
  counter-increment: steps;
  display: flex; align-items: flex-start; gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.step-list li:last-child { border-bottom: none; }
.step-list li::before {
  content: counter(steps);
  min-width: 36px; height: 36px;
  background: var(--accent);
  color: var(--white);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.9rem;
  flex-shrink: 0;
}

/* ============================================
   TABLE
   ============================================ */
.table-wrapper { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th {
  background: var(--accent);
  color: var(--white);
  text-align: left;
  padding: 12px 16px;
  font-size: 0.88rem;
  letter-spacing: .04em;
  text-transform: uppercase;
}
td { padding: 12px 16px; border-bottom: 1px solid var(--border); font-size: 0.92rem; }
tr:last-child td { border-bottom: none; }
tr:nth-child(even) td { background: var(--gray-light); }

/* ============================================
   SEARCH BAR
   ============================================ */
.search-bar {
  display: flex;
  gap: 10px;
  max-width: 520px;
  margin-bottom: 32px;
}
.search-bar input {
  flex: 1;
  padding: 10px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: var(--font);
  transition: border-color .2s;
}
.search-bar input:focus {
  outline: none;
  border-color: var(--accent);
}
.search-bar button { flex-shrink: 0; }

/* ============================================
   CONTACT FORM
   ============================================ */
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  font-size: 0.9rem;
  color: var(--gray-dark);
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: var(--font);
  transition: border-color .2s;
  background: var(--white);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.form-group textarea { resize: vertical; min-height: 120px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* ============================================
   CONTACT CARDS
   ============================================ */
.contact-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 40px; }
.contact-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  display: flex; gap: 16px; align-items: flex-start;
}
.contact-card__icon {
  font-size: 1.8rem;
  background: var(--accent-light);
  width: 52px; height: 52px;
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.contact-card__label { font-size: 0.8rem; color: var(--gray-mid); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 4px; }
.contact-card__value { font-weight: 600; color: var(--dark); }

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--dark);
  color: rgba(255,255,255,.75);
  padding: 48px 0 24px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-brand .logo__title { color: var(--white); }
.footer-brand .logo__subtitle { color: rgba(255,255,255,.5); }
.footer-desc { font-size: 0.88rem; margin-top: 12px; line-height: 1.7; color: rgba(255,255,255,.6); }
.footer-heading {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 16px;
}
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 8px; }
.footer-links a {
  color: rgba(255,255,255,.65);
  font-size: 0.88rem;
  transition: color .2s;
}
.footer-links a:hover { color: var(--accent); text-decoration: none; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 24px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.82rem;
  color: rgba(255,255,255,.4);
  flex-wrap: wrap; gap: 8px;
}

/* ============================================
   PAGE HERO (inner pages)
   ============================================ */
.page-hero {
  background: var(--dark);
  color: var(--white);
  padding: 48px 0;
  border-bottom: 4px solid var(--accent);
}
.page-hero__title { font-size: 2rem; font-weight: 800; }
.page-hero__title span { color: var(--accent); }
.page-hero__breadcrumb {
  font-size: 0.85rem;
  color: rgba(255,255,255,.55);
  margin-bottom: 10px;
}
.page-hero__breadcrumb a { color: rgba(255,255,255,.55); }
.page-hero__breadcrumb a:hover { color: var(--accent); text-decoration: none; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 900px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__card { display: none; }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .contact-cards { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .main-nav { display: none; position: fixed; inset: 72px 0 0; background: var(--white); padding: 24px; flex-direction: column; border-top: 1px solid var(--border); }
  .main-nav.open { display: flex; }
  .main-nav ul { flex-direction: column; gap: 4px; }
  .main-nav a { padding: 12px 16px; font-size: 1rem; }
  .nav-toggle { display: flex; }
  .hero__title { font-size: 1.9rem; }
  .hero { padding: 64px 0 48px; }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
}
