/*
Theme Name: hosts-center Shop
Theme URI: https://hosts-center.com
Author: hosts-center
Description: Sektörel WordPress şablonu — Mağazalar için. hosts-center Hosting müşterilerine özel.
Version: 1.1.1
Requires PHP: 8.0
Text Domain: hc-shop
*/

/* ---- design tokens ---- */
:root {
    --accent: #7c3aed;
    --accent-dark: #5b21b6;
    --ink: #14231a;
    --muted: #5b6b62;
    --bg: #fbfaf7;
    --card: #ffffff;
    --border: #e7e2d8;
    --radius: 14px;
    --shadow: 0 1px 2px rgba(20,35,26,.04), 0 8px 24px rgba(20,35,26,.06);
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--ink);
    background: var(--bg);
    line-height: 1.55;
}
a { color: var(--accent-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 1.25rem; }

/* header */
.site-header {
    background: var(--card);
    border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 50;
}
.site-header-inner {
    display: flex; align-items: center; justify-content: space-between;
    gap: 1rem; padding: 0.9rem 0;
}
.site-branding { display: flex; align-items: center; gap: 0.6rem; }
.site-branding .logo-badge {
    width: 40px; height: 40px; border-radius: 10px; background: var(--accent);
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 1.1rem; flex: none;
}
.site-title { font-size: 1.2rem; font-weight: 700; margin: 0; color: var(--ink); }
.site-title a { color: inherit; }
.site-description { font-size: 0.8rem; color: var(--muted); margin: 0; }
.main-nav ul { list-style: none; display: flex; gap: 1.4rem; margin: 0; padding: 0; }
.main-nav a { color: var(--ink); font-weight: 600; font-size: 0.95rem; }
.main-nav a:hover { color: var(--accent-dark); }
.header-cta {
    background: var(--accent); color: #fff !important; padding: 0.55rem 1.1rem;
    border-radius: 999px; font-weight: 700; font-size: 0.9rem; white-space: nowrap;
}
.header-cta:hover { background: var(--accent-dark); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 1px solid var(--border); border-radius: 8px; padding: 0.4rem 0.6rem; font-size: 1.1rem; }

/* hero */
.hero {
    background: linear-gradient(180deg, #efe7fd 0%, var(--bg) 100%);
    padding: 3.5rem 0 3rem;
    border-bottom: 1px solid var(--border);
}
.hero-inner { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 2.5rem; align-items: center; }
.hero-kicker {
    display: inline-block; background: #e5d8fb; color: var(--accent-dark);
    padding: 0.3rem 0.8rem; border-radius: 999px; font-size: 0.8rem; font-weight: 700; margin-bottom: 0.9rem;
}
.hero h1 { font-size: 2.4rem; line-height: 1.15; margin: 0 0 0.9rem; }
.hero p.lead { font-size: 1.08rem; color: var(--muted); margin: 0 0 1.6rem; max-width: 42ch; }
.hero-actions { display: flex; gap: 0.8rem; flex-wrap: wrap; }
.btn {
    display: inline-block; padding: 0.75rem 1.4rem; border-radius: 10px; font-weight: 700;
    font-size: 0.95rem; border: 2px solid transparent;
}
.btn-primary { background: var(--accent); color: #fff !important; }
.btn-primary:hover { background: var(--accent-dark); text-decoration: none; }
.btn-outline { border-color: var(--accent); color: var(--accent-dark) !important; background: #fff; }
.btn-outline:hover { background: #efe7fd; text-decoration: none; }
.hero-visual {
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
    box-shadow: var(--shadow); padding: 1.4rem; min-height: 220px;
    display: flex; flex-direction: column; justify-content: center; gap: 0.8rem;
}
.hero-visual .hv-row { display: flex; justify-content: space-between; padding: 0.5rem 0; border-bottom: 1px dashed var(--border); font-size: 0.92rem; }
.hero-visual .hv-row:last-child { border-bottom: none; }
.hero-visual .hv-row strong { color: var(--accent-dark); }

/* section shell */
section.block { padding: 3.2rem 0; }
.block-head { text-align: center; max-width: 640px; margin: 0 auto 2.2rem; }
.block-head h2 { font-size: 1.7rem; margin: 0 0 0.5rem; }
.block-head p { color: var(--muted); margin: 0; }

/* categories */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; }
.cat-card {
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 1.3rem; text-align: center; box-shadow: var(--shadow);
}
.cat-card .cat-emoji { font-size: 1.8rem; margin-bottom: 0.5rem; }
.cat-card h3 { font-size: 1rem; margin: 0 0 0.3rem; }
.cat-card p { font-size: 0.85rem; color: var(--muted); margin: 0; }

/* offers ("Angebote" custom post type) */
.offer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.2rem; }
.offer-card {
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
    overflow: hidden; box-shadow: var(--shadow);
}
.offer-photo { aspect-ratio: 4/3; overflow: hidden; background: #efe7fd; }
.offer-photo img { width: 100%; height: 100%; object-fit: cover; }
.offer-body { padding: 1.1rem 1.2rem 1.3rem; }
.offer-body h3 { margin: 0 0 0.35rem; font-size: 1.05rem; }
.offer-desc { color: var(--muted); font-size: 0.88rem; margin: 0 0 0.6rem; }
.offer-price { margin: 0; font-size: 1.15rem; font-weight: 700; color: var(--accent-dark); }
.offer-price-old { color: var(--muted); text-decoration: line-through; font-weight: 400; font-size: 0.95rem; margin-right: 0.5rem; }

/* promo strip */
.promo-strip {
    background: var(--accent); color: #fff; border-radius: var(--radius);
    padding: 1.6rem 1.8rem; display: flex; justify-content: space-between; align-items: center;
    gap: 1rem; flex-wrap: wrap;
}
.promo-strip h3 { margin: 0 0 0.2rem; font-size: 1.15rem; }
.promo-strip p { margin: 0; font-size: 0.92rem; }
.promo-strip .btn-outline { background: #fff; border-color: #fff; color: var(--accent-dark) !important; }

/* why-us */
.why-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.4rem; }
.why-card { padding: 0.4rem 0; }
.why-card .why-icon {
    width: 44px; height: 44px; border-radius: 10px; background: #efe7fd; color: var(--accent-dark);
    display: flex; align-items: center; justify-content: center; font-size: 1.3rem; margin-bottom: 0.7rem;
}
.why-card h3 { margin: 0 0 0.35rem; font-size: 1.05rem; }
.why-card p { margin: 0; color: var(--muted); font-size: 0.92rem; }

/* opening hours + contact */
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem; }
.info-card {
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 1.6rem; box-shadow: var(--shadow);
}
.info-card h3 { margin: 0 0 1rem; font-size: 1.1rem; }
.hours-row { display: flex; justify-content: space-between; padding: 0.4rem 0; border-bottom: 1px solid var(--border); font-size: 0.92rem; }
.hours-row:last-child { border-bottom: none; }
.hours-row .day { color: var(--muted); }
.contact-line { display: flex; gap: 0.6rem; align-items: flex-start; padding: 0.5rem 0; font-size: 0.95rem; }
.contact-line .ci { flex: none; }

/* footer */
.site-footer { background: var(--ink); color: #cfe0d6; padding: 2.4rem 0 1.6rem; margin-top: 2rem; }
.site-footer .container { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1.2rem; }
.site-footer a { color: #eaf5ee; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 1.6rem; padding-top: 1.2rem; font-size: 0.8rem; color: #9fb5a8; text-align: center; }
.powered-by { font-size: 0.78rem; color: #9fb5a8; }

/* page/single fallback */
.entry-content { max-width: 760px; margin: 2.5rem auto; padding: 0 1.25rem; }
.entry-content h1 { font-size: 1.8rem; }

@media (max-width: 860px) {
    .hero-inner { grid-template-columns: 1fr; }
    .info-grid { grid-template-columns: 1fr; }
    .main-nav { display: none; }
    .nav-toggle { display: inline-block; }
    .site-header.nav-open .main-nav { display: block; }
    .site-header.nav-open .main-nav ul { flex-direction: column; gap: 0.2rem; padding: 0.8rem 0; }
}

/* ===== v1.1.0 ===== */
.hc-icon { display: block; flex: none; }
.header-cta { display: inline-flex; align-items: center; gap: 0.4rem; }
.header-cta .hc-icon { display: inline-block; }
.site-branding .logo-badge .hc-icon { margin: 0; }
.main-nav a { position: relative; }

/* hero side: optional photo + hours card */
.hero-side { display: flex; flex-direction: column; gap: 1rem; }
.hero-photo { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.open-badge {
    display: inline-flex; align-items: center; gap: 0.5rem; align-self: flex-start;
    padding: 0.3rem 0.8rem; border-radius: 999px; font-size: 0.82rem; font-weight: 700;
}
.open-badge .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.open-badge.is-open { background: #dcfce7; color: #166534; }
.open-badge.is-open .dot { animation: hcpulse 2s infinite; }
.open-badge.is-closed { background: #f3f0ea; color: var(--muted); }
@keyframes hcpulse { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .open-badge.is-open .dot { animation: none; } }

/* service cards (links now) */
a.cat-card { display: block; color: inherit; transition: transform .15s, box-shadow .15s, border-color .15s; }
a.cat-card:hover { text-decoration: none; transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 10px 28px rgba(20,35,26,.1); }
.cat-card .cat-icon {
    width: 54px; height: 54px; border-radius: 14px; background: #efe7fd; color: var(--accent-dark);
    display: flex; align-items: center; justify-content: center; margin: 0 auto 0.8rem;
}
.cat-card .cat-price { display: inline-block; margin-top: 0.7rem; font-weight: 700; color: var(--accent-dark); font-size: 0.95rem; }

/* alternating section ground + price list */
section.block-alt { background: #f7f3fe; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.price-list { max-width: 720px; margin: 0 auto; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 0.4rem 1.4rem; }
.price-row { display: flex; align-items: center; gap: 0.8rem; padding: 0.95rem 0; border-bottom: 1px solid var(--border); }
.price-row:last-child { border-bottom: 0; }
.pr-name { display: flex; flex-direction: column; gap: 0.1rem; }
.pr-name > a { color: var(--ink); font-weight: 700; }
.pr-dur { display: inline-flex; align-items: center; gap: 0.3rem; font-size: 0.8rem; color: var(--muted); }
.pr-dots { flex: 1; border-bottom: 2px dotted var(--border); align-self: flex-end; margin-bottom: 0.5rem; min-width: 1rem; }
.pr-price { font-size: 1.05rem; color: var(--accent-dark); white-space: nowrap; }
.pr-book { padding: 0.35rem 0.9rem; border-radius: 999px; border: 2px solid var(--accent); font-size: 0.82rem; font-weight: 700; color: var(--accent-dark); }
.pr-book:hover { background: var(--accent); color: #fff; text-decoration: none; }

/* icons replacing emoji */
.why-card .why-icon { font-size: 0; }
.contact-line .ci { color: var(--accent-dark); padding-top: 0.15rem; }

/* single service + archive */
.svc-hero { background: linear-gradient(180deg, #efe7fd 0%, var(--bg) 100%); padding: 2.6rem 0 2.2rem; border-bottom: 1px solid var(--border); }
.svc-hero h1 { margin: 0 0 0.4rem; font-size: 2rem; }
.svc-hero .lead { margin: 0; color: var(--muted); font-size: 1.05rem; }
.svc-hero-inner { display: flex; gap: 1.2rem; align-items: center; }
.svc-icon { width: 72px; height: 72px; border-radius: 20px; background: var(--accent); color: #fff; display: flex; align-items: center; justify-content: center; flex: none; }
.crumbs { margin: 0 0 0.3rem; font-size: 0.82rem; }
.svc-body { display: grid; grid-template-columns: 1fr 300px; gap: 2.4rem; padding-top: 2.4rem; padding-bottom: 2.4rem; align-items: start; }
.svc-content { font-size: 1.02rem; }
.svc-photo { margin-bottom: 1.2rem; border-radius: var(--radius); overflow: hidden; }
.svc-card { position: sticky; top: 90px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.4rem; display: flex; flex-direction: column; gap: 0.8rem; }
.svc-card .btn { text-align: center; }
.svc-price { margin: 0; font-size: 2rem; font-weight: 800; color: var(--accent-dark); line-height: 1; }
.svc-dur { margin: 0; display: flex; align-items: center; gap: 0.4rem; color: var(--muted); }

/* phone action bar */
.mobile-bar { display: none; }
@media (max-width: 860px) {
    .svc-body { grid-template-columns: 1fr; }
    .svc-card { position: static; }
    .svc-hero-inner { flex-direction: column; align-items: flex-start; }
    .mobile-bar {
        display: grid; grid-template-columns: 1fr 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
        background: var(--card); border-top: 1px solid var(--border); box-shadow: 0 -4px 18px rgba(20,35,26,.12);
        padding: 0.6rem 0.8rem calc(0.6rem + env(safe-area-inset-bottom)); gap: 0.6rem;
    }
    .mobile-bar a { display: flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.75rem; border-radius: 10px; font-weight: 700; }
    .mobile-bar a:hover { text-decoration: none; }
    .mb-call { border: 2px solid var(--accent); color: var(--accent-dark); }
    .mb-book { background: var(--accent); color: #fff; }
    body { padding-bottom: 70px; }
    .price-row { flex-wrap: wrap; }
    .pr-dots { display: none; }
    .pr-name { flex: 1; }
}

/* service photos on cards */
.cat-card:has(.cat-photo) { padding: 0; overflow: hidden; text-align: left; }
.cat-card .cat-photo { display: block; aspect-ratio: 4/3; overflow: hidden; background: #efe7fd; }
.cat-card .cat-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
a.cat-card:hover .cat-photo img { transform: scale(1.05); }
.cat-card:has(.cat-photo) h3 { margin: 1rem 1.1rem 0.25rem; }
.cat-card:has(.cat-photo) p { margin: 0 1.1rem; }
.cat-card:has(.cat-photo) .cat-price { margin: 0.6rem 1.1rem 1.1rem; }
.svc-photo img { width: 100%; height: auto; display: block; }
@media (prefers-reduced-motion: reduce) { a.cat-card:hover .cat-photo img { transform: none; } }

/* hero with photo: full-bleed picture, copy on the left over a dark fade, hours card floating on the right */
.hero.has-photo {
    position: relative; isolation: isolate; background-size: cover; background-position: center 40%;
    min-height: 540px; display: flex; align-items: center; padding: 4rem 0; border-bottom: 0;
}
.hero.has-photo::before {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background: linear-gradient(90deg, rgba(15,15,18,.86) 0%, rgba(15,15,18,.58) 34%, rgba(15,15,18,.12) 62%, rgba(15,15,18,0) 100%);
}
.hero.has-photo .hero-inner { width: 100%; }
.hero.has-photo h1 { color: #fff; font-size: 3rem; }
.hero.has-photo p.lead { color: rgba(255,255,255,.86); }
.hero.has-photo .hero-kicker { background: rgba(254,243,199,.95); }
.hero.has-photo .btn-outline { background: transparent; border-color: rgba(255,255,255,.85); color: #fff !important; }
.hero.has-photo .btn-outline:hover { background: rgba(255,255,255,.14); }
.hero.has-photo .hero-visual { background: rgba(255,255,255,.96); backdrop-filter: blur(6px); max-width: 380px; margin-left: auto; width: 100%; }
@media (max-width: 860px) {
    .hero.has-photo { min-height: 0; padding: 2.6rem 0; }
    .hero.has-photo::before { background: linear-gradient(180deg, rgba(15,15,18,.82) 0%, rgba(15,15,18,.7) 100%); }
    .hero.has-photo h1 { font-size: 2.1rem; }
    .hero.has-photo .hero-visual { max-width: none; margin-left: 0; }
}

/* service grid: 3 per row (6 services = 3x2), incomplete last row centred instead of left-hanging */
.cat-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.4rem; }
.cat-grid > .cat-card { flex: 0 0 calc((100% - 2.8rem) / 3); max-width: calc((100% - 2.8rem) / 3); }
.cat-card:has(.cat-photo) { position: relative; display: flex; flex-direction: column; }
.cat-card:has(.cat-photo) .cat-photo { aspect-ratio: 3/2; }
.cat-card:has(.cat-photo) h3 { font-size: 1.1rem; margin-top: 1.1rem; }
.cat-card:has(.cat-photo) p { margin-bottom: 1.2rem; }
/* price as a badge on the photo corner */
.cat-card:has(.cat-photo) .cat-price {
    position: absolute; top: 0.8rem; right: 0.8rem; margin: 0;
    background: rgba(255,255,255,.96); color: var(--accent-dark); padding: 0.3rem 0.75rem;
    border-radius: 999px; font-size: 0.88rem; box-shadow: 0 2px 8px rgba(0,0,0,.18);
}
@media (max-width: 960px) {
    .cat-grid > .cat-card { flex-basis: calc((100% - 1.4rem) / 2); max-width: calc((100% - 1.4rem) / 2); }
}
@media (max-width: 560px) {
    .cat-grid { gap: 1rem; }
    .cat-grid > .cat-card { flex-basis: 100%; max-width: 100%; }
}

/* closing banner */
.custom-banner { background: var(--ink); color: #fff; padding: 3rem 0; margin-top: 2rem; }
.custom-banner-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.custom-banner-inner > div { max-width: 640px; }
.cb-eyebrow { display: inline-block; margin-bottom: 0.5rem; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: #fbbf24; }
.custom-banner h2 { margin: 0 0 0.6rem; font-size: 1.7rem; line-height: 1.2; }
.custom-banner p { margin: 0; color: rgba(255,255,255,.78); }
.custom-banner .btn { display: inline-flex; align-items: center; gap: 0.5rem; }
.site-footer { margin-top: 0; }
@media (max-width: 860px) { .custom-banner .btn { width: 100%; justify-content: center; } }
.custom-banner { background: linear-gradient(120deg, var(--accent-dark) 0%, var(--accent) 100%); }
.cb-eyebrow { color: #e5d8fb; }
.custom-banner p { color: rgba(255,255,255,.92); }
.custom-banner .btn-primary { background: #fff; color: var(--accent-dark) !important; }
.custom-banner .btn-primary:hover { background: #e5d8fb; }

/* phone header: an opened menu gets its own full-width row instead of squeezing between logo and call button */
@media (max-width: 860px) {
    .site-header-inner { flex-wrap: wrap; }
    .site-header.nav-open .main-nav { flex-basis: 100%; order: 10; border-top: 1px solid var(--border); }
    .site-header.nav-open .main-nav ul { padding: 0.4rem 0 0.2rem; gap: 0; }
    .site-header.nav-open .main-nav a { display: block; padding: 0.7rem 0; }
}
@media (max-width: 860px) {
    .site-header-inner { padding-left: 1.25rem; padding-right: 1.25rem; }
}
@media (max-width: 520px) {
    .header-cta .cta-text { display: none; }
    .header-cta { padding: 0.6rem 0.8rem; margin-left: auto; }
    .site-title { font-size: 1.05rem; }
}

/* header keeps its side gutter at every width (the base rule zeroed it, so the logo touched the edge below 1120px) */
.site-header-inner { padding-left: 1.25rem; padding-right: 1.25rem; }

/* accessibility: links inside running text must not rely on colour alone (WCAG 1.4.1) */
p:not(.site-title) a:not(.btn), .powered-by a, .footer-bottom a, .contact-line a, .site-footer p a { text-decoration: underline; text-underline-offset: 2px; }
