/* =============================================
   KUNNONPAIKKA DEMO – Base Styles
   Värimaailma, typografia, reset, utilities
   ============================================= */

:root {
    --primary: #036666;
    --primary-light: #048a8a;
    --primary-dark: #024d4d;
    --accent: #78c6a3;
    --accent-light: #d8f3dc;
    --highlight: #faf37c;
    --white: #ffffff;
    --gray-50: #f8fafa;
    --gray-100: #f0f4f4;
    --gray-200: #dce4e4;
    --gray-300: #bccece;
    --gray-500: #6a8a8a;
    --gray-600: #4a6363;
    --gray-800: #1a2e2e;
    --shadow-sm: 0 1px 3px rgba(3,102,102,0.06);
    --shadow: 0 2px 12px rgba(3,102,102,0.08);
    --shadow-lg: 0 8px 32px rgba(3,102,102,0.12);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --max-width: 1200px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    scrollbar-color: var(--primary) transparent;
    overflow-x: hidden;
}

html::-webkit-scrollbar { width: 8px; }
html::-webkit-scrollbar-track { background: transparent; }
html::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 4px; }
html::-webkit-scrollbar-thumb:hover { background: var(--primary-light); }

body {
    font-family: 'Livvic', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--gray-800);
    background: var(--white);
    line-height: 1.65;
    overflow-x: hidden;
    font-size: 16px;
}

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

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-light);
}

h1, h2, h3, h4 {
    line-height: 1.25;
    font-weight: 600;
    color: var(--gray-800);
}

h1 { font-size: clamp(2rem, 4.5vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.15rem; }
h4 { font-size: 1rem; }

p {
    color: var(--gray-600);
    max-width: 65ch;
}

/* Layout */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 80px 0;
}

.section-alt {
    background: var(--gray-50);
}

.section-header {
    margin-bottom: 48px;
}

.section-header h2 {
    color: var(--primary);
    margin-bottom: 8px;
}

.section-header p {
    font-size: 1.05rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 50px;
    font-family: 'Livvic', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    letter-spacing: 0.01em;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-light);
    color: var(--white);
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary);
    border: 2px solid var(--gray-200);
}

.btn-secondary:hover {
    border-color: var(--primary);
    transform: translateY(-1px);
}

.btn-ghost {
    background: transparent;
    color: var(--white);
    border: 1.5px solid rgba(255,255,255,0.4);
}

.btn-ghost:hover {
    border-color: var(--white);
    background: rgba(255,255,255,0.1);
    color: var(--white);
}

.btn-sm {
    padding: 10px 20px;
    font-size: 0.85rem;
}

/* Cards */
.card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--gray-200);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.card-content {
    flex: 1;
}

.card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.card h3 {
    color: var(--primary);
    margin-bottom: 8px;
}

.card p {
    font-size: 0.95rem;
}

.card-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
}

.card-header {
    margin-bottom: 12px;
}

.card-footer {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--gray-200);
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

/* Price */
.price {
    margin-top: auto;
    padding-top: 16px;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary);
}

.price small {
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--gray-500);
}

/* Service List (Spa Harmonia etc.) */
.service-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
}

.service-item {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 8px 0;
    border-bottom: 1px solid var(--gray-200);
}

.service-item:last-child {
    border-bottom: none;
}

.service-item strong {
    font-size: 0.9rem;
    color: var(--gray-800);
}

.service-item .price {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--primary);
    margin-top: 0;
    white-space: nowrap;
}

/* Info Box */
.info-box {
    padding: 24px 32px;
    background: var(--gray-50);
    border-left: 3px solid var(--primary);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    margin-top: 40px;
}

.info-box p {
    font-size: 0.9rem;
    margin-bottom: 4px;
}

.info-box p:last-child {
    margin-bottom: 0;
}

.info-box strong {
    color: var(--primary);
}

/* Feature List */
.feature-list {
    padding-left: 0;
    margin: 12px 0 0;
    font-size: 0.9rem;
    color: var(--gray-600);
    line-height: 1.8;
    list-style: none;
}

.feature-list li::before {
    content: '• ';
    color: var(--accent);
    font-weight: 700;
}

/* Tags */
.tag {
    display: inline-block;
    padding: 4px 12px;
    background: var(--accent-light);
    color: var(--primary);
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Utility */
.text-center { text-align: center; }
.text-primary { color: var(--primary); }
.mt-24 { margin-top: 24px; }
.mt-40 { margin-top: 40px; }
.mb-16 { margin-bottom: 16px; }

/* Instagram Feed */
.ig-feed {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    overflow-x: auto;
}

.ig-card {
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--gray-200);
    transition: var(--transition);
}

.ig-card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.ig-image {
    aspect-ratio: 1;
    width: 100%;
}

.ig-meta {
    padding: 12px 14px;
    background: var(--white);
}

.ig-handle {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--gray-800);
}

.ig-caption {
    font-size: 0.8rem;
    color: var(--gray-600);
    margin-top: 4px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ig-date {
    font-size: 0.7rem;
    color: var(--gray-300);
    margin-top: 6px;
    display: block;
}

/* Location Info Section */
.location-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.location-map {
    background: var(--gray-50);
    border-radius: var(--radius);
    padding: 40px;
    text-align: center;
    border: 1px solid var(--gray-200);
    min-height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.location-info h2 {
    color: var(--primary);
    margin-bottom: 16px;
}

.location-info p {
    margin-bottom: 12px;
}

.location-facts {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.location-facts li {
    padding: 6px 0;
    font-size: 0.95rem;
    color: var(--gray-800);
    font-weight: 500;
    border-bottom: 1px solid var(--gray-100);
}

.location-facts li:last-child {
    border-bottom: none;
}

/* Scroll Reveal */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }
.reveal-delay-5 { transition-delay: 0.5s; }

/* Cookie Banner */
#cookieBanner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--white);
    box-shadow: 0 -4px 24px rgba(0,0,0,0.12);
    z-index: 3000;
    padding: 24px;
    transition: transform 0.4s ease;
}

#cookieBanner.cookie-hidden {
    transform: translateY(110%);
}

.cookie-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    align-items: flex-start;
    gap: 32px;
}

.cookie-text {
    flex: 1;
}

.cookie-text strong {
    font-size: 1rem;
    color: var(--gray-800);
}

.cookie-text p {
    font-size: 0.85rem;
    margin-top: 6px;
    max-width: none;
}

.cookie-link {
    font-size: 0.82rem;
    font-weight: 600;
    margin-top: 6px;
    display: inline-block;
}

.cookie-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .section { padding: 56px 0; }
    .card-grid { grid-template-columns: 1fr !important; }
    .container { padding: 0 16px; }
    .ig-feed { grid-template-columns: repeat(2, 1fr); }
    .location-split { grid-template-columns: 1fr; }
    .cookie-inner { flex-direction: column; gap: 16px; }
    .cookie-actions { flex-direction: row; width: 100%; }
    .cookie-actions .btn { flex: 1; text-align: center; }

    /* Inline grid -osioiden ylikirjoitus */
    div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
    }

    /* Arvostelut: arvosanabalkki pinoon */
    .section-header div[style*="display:flex"][style*="justify-content:center"] {
        flex-direction: column !important;
        align-items: center !important;
        gap: 8px !important;
    }

    /* Piilota pystyviiva mobiilissa */
    .section-header span[style*="margin:0 8px"] {
        display: none !important;
    }

    /* Touch-kohteet: vieras +/- napit */
    .guest-minus,
    .guest-plus {
        width: 44px;
        height: 44px;
        font-size: 1.1rem;
    }
}
