/* ============================================================
   MJERE.SITE — Kitchen Calculator / Kuhinjske mjere
   Clean, bright, trust-focused design
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Lora:wght@400;600&display=swap');

:root {
  --bg:        #f9f7f4;
  --white:     #ffffff;
  --border:    #e8e2d9;
  --text:      #1a1a1a;
  --text-muted:#6b6560;
  --accent:    #e8650a;
  --accent-dk: #c5550a;
  --green:     #2d7a4f;
  --radius:    10px;
  --radius-lg: 18px;
  --shadow:    0 2px 16px rgba(0,0,0,.07);
  --shadow-lg: 0 8px 40px rgba(0,0,0,.10);
  --font:      'Inter', sans-serif;
  --font-serif:'Lora', Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); background: var(--bg); color: var(--text); font-size: 16px; line-height: 1.6; }

/* ─── HEADER ─── */
header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 1px 8px rgba(0,0,0,.06);
}
.header-inner {
  max-width: 1100px; margin: 0 auto; padding: 0 24px;
  display: flex; align-items: center; justify-content: space-between; height: 64px;
}
.logo {
  font-family: var(--font-serif); font-size: 1.5rem; font-weight: 600;
  color: var(--text); text-decoration: none;
}
.logo span { color: var(--accent); }
nav { display: flex; gap: 4px; align-items: center; }
nav a {
  font-size: .875rem; font-weight: 500; color: var(--text-muted);
  text-decoration: none; padding: 8px 14px; border-radius: 8px; transition: all .18s;
}
nav a:hover, nav a.active { color: var(--accent); background: #fff3ee; }
.hamburger { display: none; background: none; border: none; cursor: pointer; padding: 6px; flex-direction: column; gap: 5px; }
.hamburger span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: all .3s; }

/* ─── HERO ─── */
.hero {
  background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
  color: #fff; padding: 72px 24px; text-align: center;
}
.hero-inner { max-width: 700px; margin: 0 auto; }
.hero-tag {
  display: inline-block; background: rgba(232,101,10,.18); border: 1px solid rgba(232,101,10,.4);
  color: var(--accent); font-size: .75rem; font-weight: 700; letter-spacing: .16em;
  text-transform: uppercase; padding: 6px 16px; border-radius: 20px; margin-bottom: 22px;
}
.hero h1 {
  font-family: var(--font-serif); font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.15; margin-bottom: 18px; font-weight: 600;
}
.hero h1 em { color: var(--accent); font-style: normal; }
.hero p { font-size: 1.05rem; color: rgba(255,255,255,.72); margin-bottom: 36px; max-width: 560px; margin-left: auto; margin-right: auto; }
.hero-tools {
  display: flex; gap: 10px; justify-content: center; flex-wrap: wrap;
}
.hero-tools a {
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.22);
  color: #fff; text-decoration: none; padding: 10px 20px; border-radius: 50px;
  font-size: .875rem; font-weight: 600; transition: all .2s;
}
.hero-tools a:hover { background: var(--accent); border-color: var(--accent); }

/* ─── CONTAINER ─── */
.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }

/* ─── TOOL GRID (homepage) ─── */
.tools-section { padding: 64px 0; }
.section-title {
  font-family: var(--font-serif); font-size: 1.75rem; font-weight: 600;
  color: var(--text); margin-bottom: 8px;
}
.section-subtitle { font-size: .95rem; color: var(--text-muted); margin-bottom: 36px; }
.tools-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 22px;
}
.tool-card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 28px; display: flex; flex-direction: column; gap: 14px;
  box-shadow: var(--shadow); text-decoration: none; color: inherit;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.tool-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--accent); }
.tool-icon { font-size: 2rem; line-height: 1; }
.tool-card h3 { font-family: var(--font-serif); font-size: 1.2rem; font-weight: 600; color: var(--text); }
.tool-card p { font-size: .9rem; color: var(--text-muted); line-height: 1.65; flex: 1; }
.tool-card-cta {
  display: inline-flex; align-items: center; gap: 6px; font-size: .85rem;
  font-weight: 700; color: var(--accent); margin-top: 4px;
}

/* ─── TOOL PAGE LAYOUT ─── */
.tool-page { padding: 48px 0 80px; }
.tool-page-inner { max-width: 900px; margin: 0 auto; padding: 0 24px; }
.tool-breadcrumb {
  font-size: .82rem; color: var(--text-muted); margin-bottom: 28px; display: flex; gap: 6px; align-items: center;
}
.tool-breadcrumb a { color: var(--text-muted); text-decoration: none; }
.tool-breadcrumb a:hover { color: var(--accent); }
.tool-breadcrumb span { color: var(--border); }

.tool-hero-img {
  width: 100%; height: 280px; object-fit: cover;
  border-radius: var(--radius-lg); margin-bottom: 36px;
  box-shadow: var(--shadow-lg);
}

.tool-header { margin-bottom: 32px; }
.tool-header h1 { font-family: var(--font-serif); font-size: clamp(1.7rem, 4vw, 2.4rem); font-weight: 600; margin-bottom: 10px; }
.tool-header p { font-size: 1rem; color: var(--text-muted); line-height: 1.75; max-width: 640px; }

/* ─── CALCULATOR CARD ─── */
.calc-card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 36px; box-shadow: var(--shadow); margin-bottom: 36px;
}
.calc-card-title { font-family: var(--font-serif); font-size: 1.25rem; font-weight: 600; margin-bottom: 24px; color: var(--text); }

.calc-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.calc-field { display: flex; flex-direction: column; gap: 7px; }
.calc-field label { font-size: .82rem; font-weight: 700; color: #444; text-transform: uppercase; letter-spacing: .05em; }
.calc-field input, .calc-field select {
  padding: 12px 14px; border: 1.5px solid var(--border); border-radius: var(--radius);
  font-family: var(--font); font-size: .97rem; background: var(--bg); color: var(--text); transition: border-color .18s;
}
.calc-field input:focus, .calc-field select:focus { outline: none; border-color: var(--accent); }
.calc-field-full { grid-column: 1 / -1; }

.calc-btn {
  width: 100%; padding: 15px; margin-top: 8px;
  background: var(--accent); color: #fff; font-family: var(--font);
  font-weight: 700; font-size: 1rem; border: none; border-radius: var(--radius);
  cursor: pointer; transition: background .2s, transform .15s; letter-spacing: .03em;
}
.calc-btn:hover { background: var(--accent-dk); transform: translateY(-2px); }

.calc-result {
  background: #fff8f4; border: 1.5px solid #f5c4a8; border-left: 4px solid var(--accent);
  border-radius: var(--radius); padding: 22px 26px; margin-top: 20px; display: none;
}
.calc-result.visible { display: block; }
.calc-result-label { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--text-muted); margin-bottom: 8px; }
.calc-result-number { font-family: var(--font-serif); font-size: 2.6rem; font-weight: 600; color: var(--accent); line-height: 1; margin-bottom: 6px; }
.calc-result-sub { font-size: .88rem; color: var(--text-muted); line-height: 1.55; }

/* ─── INFO BOX ─── */
.info-box {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 28px; margin-bottom: 28px; box-shadow: var(--shadow);
}
.info-box h2 { font-family: var(--font-serif); font-size: 1.2rem; color: var(--text); margin-bottom: 14px; }
.info-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.info-table th { text-align: left; padding: 10px 12px; background: var(--bg); font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-muted); border-bottom: 2px solid var(--border); }
.info-table td { padding: 10px 12px; border-bottom: 1px solid var(--border); color: var(--text-muted); }
.info-table tr:last-child td { border-bottom: none; }
.info-table td:first-child { font-weight: 600; color: var(--text); }
.info-table tr:hover td { background: var(--bg); }

.tip-box {
  background: #f0faf5; border: 1px solid #b6dfc9; border-left: 4px solid var(--green);
  border-radius: var(--radius); padding: 18px 20px; font-size: .9rem; color: #1a4a30; line-height: 1.65; margin-bottom: 20px;
}
.tip-box strong { display: block; margin-bottom: 4px; }

/* ─── HOW TO USE ─── */
.steps { display: flex; flex-direction: column; gap: 16px; margin-top: 16px; }
.step { display: flex; gap: 16px; align-items: flex-start; }
.step-num {
  width: 32px; height: 32px; min-width: 32px; border-radius: 50%;
  background: var(--accent); color: #fff; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: .85rem;
}
.step p { font-size: .92rem; color: var(--text-muted); line-height: 1.65; padding-top: 4px; }

/* ─── STATIC PAGE ─── */
.static-page { max-width: 780px; margin: 0 auto; padding: 56px 24px 80px; }
.static-page h1 { font-family: var(--font-serif); font-size: 2rem; margin-bottom: 6px; }
.static-page .updated { font-size: .82rem; color: var(--text-muted); margin-bottom: 36px; }
.static-page h2 { font-family: var(--font-serif); font-size: 1.25rem; color: var(--text); margin: 32px 0 10px; }
.static-page p, .static-page li { font-size: .97rem; color: var(--text-muted); line-height: 1.8; margin-bottom: 10px; }
.static-page ul { padding-left: 22px; }
.static-page a { color: var(--accent); }

/* ─── CONTACT FORM ─── */
.contact-form { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 32px; margin-top: 32px; box-shadow: var(--shadow); }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: .85rem; font-weight: 700; margin-bottom: 7px; }
.form-group input, .form-group textarea {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--border); border-radius: var(--radius);
  font-family: var(--font); font-size: .95rem; background: var(--bg); color: var(--text); transition: border-color .18s;
}
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--accent); }
.form-group textarea { height: 130px; resize: vertical; }
.btn-submit {
  background: var(--accent); color: #fff; font-family: var(--font); font-weight: 700;
  font-size: .95rem; padding: 13px 32px; border: none; border-radius: 50px; cursor: pointer; transition: all .2s;
}
.btn-submit:hover { background: var(--accent-dk); transform: translateY(-2px); }

/* ─── 404 ─── */
.page-404 { text-align: center; padding: 80px 24px; }
.page-404 h1 { font-family: var(--font-serif); font-size: 2.2rem; margin-bottom: 14px; }
.page-404 p { color: var(--text-muted); margin-bottom: 28px; }

/* ─── FOOTER ─── */
footer { background: #1a1a1a; color: rgba(255,255,255,.65); padding: 52px 24px 28px; margin-top: 0; }
.footer-inner { max-width: 1100px; margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-logo { font-family: var(--font-serif); font-size: 1.3rem; color: #fff; text-decoration: none; }
.footer-logo span { color: var(--accent); }
.footer-desc { font-size: .875rem; line-height: 1.7; margin-top: 10px; color: rgba(255,255,255,.45); }
.footer-col h4 { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: rgba(255,255,255,.45); margin-bottom: 14px; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: .875rem; color: rgba(255,255,255,.55); text-decoration: none; transition: color .18s; }
.footer-col a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); padding-top: 22px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: .8rem; color: rgba(255,255,255,.3); }

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
  nav { display: none; }
  nav.open { display: flex; flex-direction: column; position: absolute; top: 64px; left: 0; right: 0; background: var(--white); padding: 16px 24px; border-bottom: 1px solid var(--border); box-shadow: var(--shadow); }
  header { position: relative; }
  .hamburger { display: flex; }
  .tools-grid { grid-template-columns: 1fr; }
  .calc-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .hero { padding: 52px 20px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 480px) {
  .hero-tools { flex-direction: column; align-items: center; }
}
