/* TIETOKONEKORJAAMO /UUSI style.css — 2026-02-10 (siivottu + korjaukset) */

:root{
  --text:#4e4e3d;
  --muted:#464032;

  --bg:#efe9d8;                 /* lämmin beige tausta */
  --paper:#fbf8ef;              /* “paperi” korttien tausta */
  --line:rgba(78,78,61,.22);

  --green:#6fa506;              /* oma vihreä */
  --green2:#86c111;             /* hover */

  --shadow: 0 10px 22px rgba(0,0,0,.16);
  --r: 18px;
}

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

body{
  font-family: Arial, Verdana, sans-serif;
  color: var(--text);
  min-height:100vh;

  background:
    radial-gradient(1200px 700px at 15% 0%, rgba(111,165,6,.10) 0%, transparent 55%),
    radial-gradient(900px 600px at 85% 10%, rgba(202,191,165,.55) 0%, transparent 55%),
    linear-gradient(180deg, rgba(255,255,255,.55), transparent 35%),
    var(--bg);
}

.wrap{max-width:1040px;margin:0 auto;padding:0 16px}

/* Saavutettavuus: skip-link */
.skip{
  position:absolute;left:-9999px;top:auto;width:1px;height:1px;overflow:hidden;
}
.skip:focus{
  left:16px;top:16px;width:auto;height:auto;
  background:#fff;color:#000;
  padding:10px 12px;border-radius:10px;
  border:1px solid rgba(0,0,0,.15);
}

/* Linkit */
a{ color: var(--green); text-decoration:underline; }
a:hover{ color: var(--green2); }

/* Header */
.site-header{
  position:sticky;top:0;z-index:50;
  background: linear-gradient(180deg, #3f6b4f 0%, #2f5f44 100%);
  border-bottom:1px solid rgba(0,0,0,.10);
}
.site-header .wrap{position:relative;} /* ankkuroidaan mobiilidropdown */

.header-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:14px 0;
}

.brand-link{
  font-weight:800;
  letter-spacing:.08em;
  text-decoration:none;
  color:#fff;
}

.brand-sub{
  font-size:.92rem;
  color:rgba(255,255,255,.85);
  margin-top:4px;
}

.nav{
  display:flex;
  gap:14px;
  flex-wrap:wrap;
  justify-content:flex-end;
}
.nav a{
  text-decoration:none;
  color:rgba(255,255,255,.92);
  padding:8px 10px;
  border-radius:12px;
}
.nav a:hover{
  background: rgba(255,255,255,.18);
  color:#fff;
}

.nav-toggle{
  display:none;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.25);
  background: rgba(255,255,255,.14);
  color:#fff;
  cursor:pointer;
}

/* Main spacing */
.site-main{padding:22px 0 12px} /* pienempi tila footeriin */
.hero{padding:10px 0 18px}

/* Paperi-tyyli korteille */
.hero-card,
.card,
.note,
.footer-box{
  border:1px solid var(--line);
  border-radius: var(--r);
  box-shadow: var(--shadow);
  background:
    linear-gradient(0deg, rgba(255,255,255,.92), rgba(255,255,255,.92)),
    repeating-linear-gradient(0deg, rgba(0,0,0,.015) 0, rgba(0,0,0,.015) 1px, transparent 1px, transparent 6px),
    var(--paper);
}

/* Korttien sisäpaddingit */
.hero-card{padding:18px}
.card{padding:16px}
.note{
  margin-top:14px;
  padding:12px;
  border-radius:14px;
  color: var(--muted);
}

/* Typografia */
h1{margin:0 0 10px;font-size:2rem}
.lead{margin:0 0 14px;color:var(--muted);font-size:1.05rem}

.card h2{margin:0 0 10px;font-size:1.2rem}
.muted{color:var(--muted)}

.list{
  margin:10px 0 0;
  padding-left:18px;
  color:var(--muted);
}
.list li{margin:6px 0}

/* Gridit */
.grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:14px;
  margin-top:14px;
}

/* Napit */
.btn{
  display:inline-block;
  background: var(--green);
  color:#fff;
  text-decoration:none;
  border:none;
  padding:10px 14px;
  border-radius:14px;
  box-shadow: 0 10px 18px rgba(111,165,6,.22);
  font-weight:700;
}
.btn:hover{ background: var(--green2); }

.btn.ghost{
  background: rgba(255,255,255,.78);
  border:1px solid rgba(0,0,0,.12);
  color: var(--muted);
  box-shadow:none;
}
.btn.small{
  padding:8px 10px;
  border-radius:12px;
  font-size:.95rem;
}

/* Logo & kuvat */
.hero-logo{max-width:180px;margin-bottom:14px}

.hero-image{
  display:block;
  width:100%;
  border-radius: var(--r);
  box-shadow: var(--shadow);
}

/* Index-kuvakortin välit (ylös ja alas) */
.index-image-card{
  margin-top:14px;
  margin-bottom:0;
}

/* Maps */
.map iframe{
  width:100%;
  height:240px;
  border:0;
  border-radius:12px;
  display:block;
}

/* Footer */
.site-footer{
  padding:12px 0 14px; /* pienempi väli */
}

.footer-box{
  padding:18px 16px;
}

.footer-grid{
  display:grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap:14px;
  align-items:start;
}

.footer-title{font-weight:700;margin-bottom:8px}
.footer-links{display:flex;flex-direction:column;gap:8px}
.footer-bottom{margin-top:10px;color:var(--muted);font-size:.95rem}

/* LINKIT-sivu: 3 palstaa */
.links-card h1{margin-bottom:18px}

.links-grid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:26px;
  margin-top:10px;
}

.links-col h2{
  font-size:1.2rem;
  margin-bottom:10px;
  color: var(--text);
}

/* Responsive */
@media (max-width: 860px){
  /* mobiilivalikko: piilota normaali nav, näytä nappi */
  .nav{display:none}
  .nav-toggle{display:inline-block}

  /* tärkein: kaikki 3-palstaiset gridit 1 palstaan */
  .grid{grid-template-columns: 1fr;}
  .footer-grid{grid-template-columns: 1fr;}
  .links-grid{grid-template-columns: 1fr; gap:18px;}

  h1{font-size:1.7rem}

  /* dropdown-nav */
  .nav.open{
    display:flex;
    position:absolute;
    right:16px;
    top:62px; /* säädä jos haluat korkeammalle/matalammalle */
    flex-direction:column;
    align-items:stretch;
    gap:6px;

    background: rgba(47,95,68,.98);
    border:1px solid rgba(255,255,255,.25);
    border-radius:14px;
    padding:10px;
    box-shadow: 0 12px 26px rgba(0,0,0,.25);
    min-width: 210px;
    z-index: 999;
  }

  .nav.open a{
    padding:10px 12px;
    border-radius:12px;
    text-decoration:none;
    color:#fff;
    white-space:nowrap;
  }
  .nav.open a:hover{
    background: rgba(255,255,255,.16);
  }
}

/* Myynti-sivu: tuotekortit */
.products-grid{margin-top:14px}

.product-badges{
  display:flex; gap:10px; align-items:center; flex-wrap:wrap;
  margin-bottom:10px;
}
.product-price{
  font-weight:800;
  color: var(--text);
  background: rgba(111,165,6,.10);
  border:1px solid var(--line);
  padding:6px 10px;
  border-radius: 999px;
}
.product-status{
  font-weight:800;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid var(--line);
  background: rgba(255,255,255,.7);
}
.product-status.ok{background: rgba(134,193,17,.12)}
.product-status.warn{background: rgba(202,191,165,.35)}
.product-status.muted{opacity:.75}

.product-image{
  margin:10px 0;
  border:1px solid var(--line);
  border-radius:14px;
  background:#fff;
  overflow:hidden;

  aspect-ratio: 4 / 3;
  display:flex;
  align-items:center;
  justify-content:center;
}

.product-image img{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
}

.product-price{
  font-weight:700;
  line-height:1.25;
}

.product-price .price-note{
  font-weight:400;
  font-size:.9em;
  color:var(--muted);
}

.product-price .price-sub{
  font-weight:400;
  font-size:.85em;   /* ← pari napsua pienempi */
  color:var(--muted);
}
