/*
Theme Name: Code Mine
Theme URI: https://codemine.hr
Author: CODE MINE d.o.o.
Description: Lightweight single-page theme for CODE MINE d.o.o. All texts are editable in Appearance → Customize → Code Mine.
Version: 1.0.1
Requires at least: 6.0
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: codemine
*/

:root {
  --bg: #0e1116;
  --bg-2: #151a21;
  --line: #262d38;
  --text: #e7eaee;
  --muted: #9aa4b2;
  --ore: #f2a33a;
  --ore-2: #ffcf7a;
  --radius: 14px;
  --max: 1120px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--ore); text-decoration: none; }
a:hover { color: var(--ore-2); }
img { max-width: 100%; height: auto; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }
.screen-reader-text { position: absolute; left: -9999px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(14, 17, 22, .82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 800; letter-spacing: .08em; }
.brand:hover { color: var(--text); }
.brand svg { width: 30px; height: 30px; }
.brand img { max-height: 40px; width: auto; }
.nav { display: flex; gap: 28px; }
.nav a { color: var(--muted); font-size: 15px; font-weight: 500; }
.nav a:hover { color: var(--text); }
@media (max-width: 640px) { .nav a:not(.nav-cta) { display: none; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 22px; border-radius: 999px;
  font-weight: 600; font-size: 15px;
  border: 1px solid var(--line);
  color: var(--text);
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:hover { transform: translateY(-1px); border-color: var(--muted); color: var(--text); }
.btn-primary { background: var(--ore); border-color: var(--ore); color: #1a1205; }
.btn-primary:hover { background: var(--ore-2); border-color: var(--ore-2); color: #1a1205; }

/* Hero */
.hero { position: relative; overflow: hidden; padding: 120px 0 110px; }
.hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(600px 300px at 80% 10%, rgba(242,163,58,.16), transparent 70%),
    linear-gradient(transparent 0 calc(100% - 1px), var(--line) 0) 0 0 / 100% 48px,
    linear-gradient(90deg, transparent 0 calc(100% - 1px), var(--line) 0) 0 0 / 48px 100%;
  opacity: .55;
  mask-image: linear-gradient(to bottom, #000 40%, transparent);
  -webkit-mask-image: linear-gradient(to bottom, #000 40%, transparent);
}
.hero .wrap { position: relative; }
.eyebrow {
  font-family: var(--mono); font-size: 13px; color: var(--ore);
  letter-spacing: .12em; text-transform: uppercase; margin: 0 0 18px;
}
.hero h1 {
  font-size: clamp(40px, 7vw, 80px); line-height: 1.04;
  letter-spacing: -.03em; margin: 0 0 24px; max-width: 14ch;
}
.hero h1 span { color: var(--ore); }
.hero p.lead { font-size: clamp(18px, 2vw, 21px); color: var(--muted); max-width: 58ch; margin: 0 0 36px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; }
.clouds { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 56px; }
.chip {
  font-family: var(--mono); font-size: 13px; color: var(--muted);
  border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px;
  background: var(--bg-2);
}

/* Sections */
section { padding: 96px 0; border-top: 1px solid var(--line); }
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head h2 { font-size: clamp(30px, 4vw, 44px); line-height: 1.12; letter-spacing: -.02em; margin: 0 0 14px; }
.section-head p { color: var(--muted); margin: 0; }

.grid { display: grid; gap: 20px; grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .grid { grid-template-columns: 1fr; } }
.card {
  background: var(--bg-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 30px;
  transition: border-color .2s ease, transform .2s ease;
}
.card:hover { border-color: rgba(242,163,58,.5); transform: translateY(-2px); }
.card .icon {
  width: 44px; height: 44px; border-radius: 10px;
  display: grid; place-items: center;
  background: rgba(242,163,58,.12); color: var(--ore); margin-bottom: 20px;
}
.card .icon svg { width: 22px; height: 22px; }
.card h3 { font-size: 20px; margin: 0 0 10px; }
.card p { color: var(--muted); margin: 0; font-size: 16px; }

/* About */
.about { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }
@media (max-width: 900px) { .about { grid-template-columns: 1fr; } }
.about .section-head { margin-bottom: 0; }
.about .section-head p + p { margin-top: 16px; }
.terminal {
  background: #0a0c10; border: 1px solid var(--line); border-radius: var(--radius);
  font-family: var(--mono); font-size: 14px; overflow: hidden;
}
.terminal .bar { display: flex; gap: 7px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.terminal .bar i { width: 11px; height: 11px; border-radius: 50%; background: #2b313b; display: block; }
.terminal pre { margin: 0; padding: 22px 20px; color: var(--muted); white-space: pre-wrap; line-height: 1.8; }
.terminal .k { color: var(--ore); }
.terminal .ok { color: #7bd88f; }

/* Contact */
.contact-box {
  background: linear-gradient(135deg, rgba(242,163,58,.14), rgba(242,163,58,.02));
  border: 1px solid rgba(242,163,58,.35); border-radius: 20px;
  padding: 56px; display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap;
}
.contact-box h2 { font-size: clamp(28px, 4vw, 40px); margin: 0 0 8px; letter-spacing: -.02em; }
.contact-box p { margin: 0; color: var(--muted); }
@media (max-width: 640px) { .contact-box { padding: 32px; } }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 36px 0; color: var(--muted); font-size: 14px; }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-footer .legal { font-family: var(--mono); font-size: 13px; }

/* Generic content (other pages/posts) */
.content { padding: 72px 0; }
.content .entry { max-width: 760px; margin: 0 auto 64px; }
.content h1 { font-size: clamp(32px, 5vw, 48px); letter-spacing: -.02em; line-height: 1.1; }
.content .entry-content { color: #c9cfd7; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
