* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--paper) var(--paperipinta); font-size: 16px; line-height: 1.45; }
h1, h2, h3, p, figure { margin: 0; }
h1, h2, h3 { font-family: var(--otsikkokirjasin); font-weight: 500; line-height: 1.08; }
a { color: #793129; text-underline-offset: .22em; }
button { font: inherit; }
:focus-visible { outline: 3px solid #176d68; outline-offset: 4px; }
.ylareuna, main { width: min(100% - 2.5rem, 1100px); margin-inline: auto; }
.ylareuna { display: flex; justify-content: space-between; align-items: center; padding-block: 1rem; border-bottom: 1px solid #bda17c; }
.ylareuna a, footer:not(.tekijät) a { display: inline-flex; align-items: center; min-height: 44px; gap: .45rem; font-weight: 720; }
#kieli { min-width: 44px; min-height: 44px; background: #fffaf1; color: var(--ink); border: 1px solid #a68059; border-radius: 8px; cursor: pointer; }
#kieli:hover { background: #ecdec5; }
.alku { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); column-gap: clamp(1.6rem, 5vw, 4.5rem); row-gap: .65rem; align-items: center; padding-block: clamp(2rem, 4vw, 3.75rem); }
h1 { color: var(--red); font-size: clamp(3rem, 7vw, 6rem); letter-spacing: -.065em; line-height: .95; text-wrap: balance; }
.johdanto { font-size: clamp(1.08rem, 2vw, 1.28rem); max-width: 34ch; margin-block: 1.1rem .9rem; }
.kummijohdanto h1 { font-size: clamp(3rem, 5.9vw, 5rem); }
.kummitarjous { grid-column: 1; }
.kummipaketti { display: grid; gap: .35rem; max-width: 42ch; border-left: 3px solid #53745e; padding-left: .9rem; }
.kummipaketti h2 { font-size: 1.5rem; }
.kummilupaus { color: #344d39; font-weight: 740; }
#kummilaskuri { width: fit-content; margin-top: 1rem; padding: .35rem .7rem; background: #e0ead9; border: 1px solid #75917a; border-radius: 6px; font-weight: 720; }
.postikortti { grid-column: 2; grid-row: 1 / span 2; align-self: start; margin-top: clamp(2rem,7vw,6rem); transform: rotate(1.8deg); padding: .55rem .55rem .35rem; background: #fffaf1 var(--paperipinta); box-shadow: 0 10px 18px #52453827; border: 1px solid #cbb08c; }
.postikortti canvas { display: block; width: 100%; height: auto; border: 1px solid #a38769; }
figcaption { padding-top: .35rem; text-align: center; font: italic 1rem var(--otsikkokirjasin); color: #645040; }
.paketit { padding-top: 1.5rem; border-top: 1px dashed #a68059; }
h2 { font-size: clamp(1.65rem, 4.4vw, 2.5rem); letter-spacing: -.04em; }
.toririvi { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .8rem; list-style: none; margin: 1.2rem 0 0; padding: 0; }
.toririvi li { display: flex; flex-direction: column; gap: .45rem; border: 1px solid #baa184; border-top: 5px solid var(--red); background: #fffaf1 var(--paperipinta); border-radius: 4px 4px 9px 9px; padding: .75rem .9rem; }
.toririvi li:nth-child(even) { border-top-color: #53745e; }
.toririvi h3 { font-size: 1.35rem; }
.hinta { color: #793129; font-size: 1.1rem; font-weight: 760; }
.taloja { margin-top: auto; padding-top: .5rem; border-top: 1px dashed #d6be9c; font-weight: 730; }
.alv { margin-top: .9rem; color: #645040; font-size: .9rem; }
footer:not(.tekijät) { display: flex; flex-wrap: wrap; gap: .25rem 1.2rem; justify-content: space-between; align-items: center; margin-top: 1.3rem; padding-block: .7rem 1.45rem; border-top: 1px solid #bda17c; }
.myyntitila { margin-top: .9rem; color: #645040; font-size: .9rem; }
.myyntitila p + p { margin-top: .15rem; }
footer > div { max-width: 58ch; }
footer nav { display: flex; flex-wrap: wrap; gap: 0 1.2rem; }
.ehdot { max-width: 700px; padding-block: clamp(2rem, 5vw, 4rem); }
.ehdot h1 { font-size: clamp(2.65rem, 7vw, 5rem); }
.ehdot section { margin-top: 1.65rem; }
.ehdot p { margin-top: .55rem; }
.ehdot dl { margin-block: .8rem 0; }
.ehdot dt { font-weight: 740; }
.ehdot dd { margin: .25rem 0 .85rem; }
.ehdot a { overflow-wrap: anywhere; }
@media (max-width: 880px) {
  .toririvi { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .alku { grid-template-columns: 1fr; gap: 1rem; padding-top: 1.5rem; }
  .postikortti { grid-column: 1; grid-row: auto; margin: 0 .3rem .3rem; }
  .postikortti canvas { height: clamp(105px, 29vw, 170px); object-fit: cover; object-position: 50% 42%; }
  .johdanto { margin-bottom: 0; }
}
@media (max-width: 410px) {
  .toririvi { grid-template-columns: 1fr; }
}

.kummitoimet { margin-top: .5rem; }
.kummirasti { display: grid; grid-template-columns: 2.7rem 1fr; align-items: start; gap: .45rem; padding-block: .4rem; cursor: pointer; }
.kummirasti input { width: 1.4rem; height: 1.4rem; margin: .35rem auto; accent-color: #355849; }
.myyntinappi { display: block; min-height: 44px; width: fit-content; max-width: 100%; padding: .5rem .9rem; margin-block: .55rem; font-weight: 750; border: 1px solid #294439; border-radius: 9px; background: #355849; color: #fffaf1; cursor: pointer; }
.myyntinappi:hover { background: #294439; }
.myyntinappi:disabled { opacity: .68; cursor: wait; }
.myyntipaperi { padding: 1rem clamp(.9rem, 3vw, 1.4rem); margin-block: 1.1rem; border: 1px solid #cbb08c; border-radius: 4px 4px 10px 10px; background: #fffaf1 var(--paperipinta); }
.myyntipaperi summary { width: fit-content; min-height: 44px; align-content: center; color: #793129; font-weight: 750; cursor: pointer; }
.myyntilomake { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .65rem 1.1rem; margin-block: .75rem; max-width: 670px; align-items: start; }
.myyntilomake label { display: grid; gap: .22rem; font-weight: 670; }
.myyntilomake input, .myyntilomake select { width: 100%; min-width: 0; min-height: 44px; padding: .45rem; border: 1px solid #9e8060; border-radius: 6px; color: var(--ink); background: #fffcf4; font: inherit; font-weight: 450; }
.myyntilomake input[type="color"] { padding: .17rem; }
.myyntilomake small { font-weight: 450; }
#kummi-tila:not(:empty), #kummi-postitila:not(:empty), #yritys-tila:not(:empty) { padding: .55rem .65rem; background: #e5eedf; border-radius: .5rem; }
#kummi-leivo a, #kummi-maksettu a { display: inline-flex; align-items: center; min-height: 44px; }
#kumppanikortit { margin-block: 1.3rem; }
#kumppanit-lista { overflow-wrap: anywhere; }
#kumppanit-lista small { color: #344d39; font-weight: 730; }
#kumppanit-lista a { min-height: 44px; display: inline-flex; align-items: center; width: fit-content; }
#kaupan-kuva { display: block; margin: 1rem auto; width: min(100%,480px); height: auto; background: #e8ede2; border: 1px dashed #9e8060; border-radius: .6rem; }
@media (max-width: 620px) {
  .myyntilomake { grid-template-columns: minmax(0,1fr); }
}
#kumppanit-lista canvas { display: block; width: 100%; height: auto; background: #e8ede2; border-radius: 5px; }
