/*
Theme Name: Kakobuy Spreadsheet CN
Theme URI: https://sheetcn.com/
Author: SheetCN
Author URI: https://sheetcn.com/
Description: Clean, bright, SEO-optimized WordPress theme for kakobuy spreadsheet guides with 8 product categories, a Guide dropdown of 6 pre-populated SEO articles, and clear CTAs to sheetcn.com. Soft coral + teal + sunshine palette.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: kakobuy-spreadsheet-cn
Tags: seo, blog, custom-menu, two-columns, responsive-layout, light
*/

/* =========================================================
   RESET + BASE
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    font-family: 'Inter', 'Helvetica Neue', 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', Arial, sans-serif;
    color: #1f3a4b;
    background:
        radial-gradient(1200px 600px at 8% -10%, #ffe4d6 0%, transparent 60%),
        radial-gradient(900px 500px at 92% 0%, #d2f1ef 0%, transparent 60%),
        radial-gradient(900px 700px at 50% 110%, #fff2c4 0%, transparent 60%),
        linear-gradient(180deg, #fdfaf5 0%, #f3fbfa 100%);
    background-attachment: fixed;
    line-height: 1.65;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; height: auto; display: block; }
a { color: #ff6a5b; text-decoration: none; transition: color .2s ease; }
a:hover { color: #e04631; }

h1, h2, h3, h4 {
    font-family: 'Poppins', 'Inter', 'Segoe UI', sans-serif;
    color: #103141;
    line-height: 1.2;
    margin: 0 0 .6em;
    letter-spacing: -0.01em;
}
h1 { font-size: clamp(2rem, 4.2vw, 3.1rem); font-weight: 800; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); font-weight: 700; }
h3 { font-size: 1.25rem; font-weight: 700; }
p  { margin: 0 0 1em; }

.container {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 8px; padding: 14px 28px; border-radius: 999px;
    font-weight: 700; letter-spacing: .01em; font-size: 15px;
    cursor: pointer; border: 0;
    transition: transform .18s ease, box-shadow .18s ease, background .25s ease;
    text-align: center; white-space: nowrap;
}
.btn-primary {
    color: #fff;
    background: linear-gradient(135deg, #ff8f6b 0%, #ff6a5b 55%, #ffb84d 100%);
    box-shadow: 0 10px 24px -10px rgba(255,106,91,.55);
}
.btn-primary:hover { transform: translateY(-2px); color:#fff; box-shadow: 0 16px 30px -12px rgba(255,106,91,.65); }
.btn-secondary {
    color: #0e5b55; background: #fff; border: 2px solid #c6ece7;
    box-shadow: 0 10px 24px -14px rgba(14,91,85,.3);
}
.btn-secondary:hover { color:#0e5b55; background:#f1fbf9; transform: translateY(-2px); }
.btn-dark {
    color: #fff;
    background: linear-gradient(135deg, #0e5b55 0%, #1f8c82 100%);
    box-shadow: 0 10px 24px -10px rgba(14,91,85,.5);
}
.btn-dark:hover { color:#fff; transform: translateY(-2px); }

/* =========================================================
   HEADER / NAV
   ========================================================= */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(255,255,255,.85);
    backdrop-filter: saturate(1.4) blur(10px);
    -webkit-backdrop-filter: saturate(1.4) blur(10px);
    border-bottom: 1px solid rgba(255, 106, 91, 0.08);
}
.header-inner {
    display: flex; align-items: center; justify-content: space-between;
    gap: 20px; padding: 14px 0;
}
.site-brand {
    display: flex; align-items: center; gap: 10px;
    font-family: 'Poppins', sans-serif; font-weight: 800;
    font-size: 1.25rem; color: #103141;
}
.site-brand .brand-mark {
    width: 36px; height: 36px; border-radius: 10px;
    background: linear-gradient(135deg,#ff8f6b,#0e5b55);
    display:inline-flex;align-items:center;justify-content:center;color:#fff;font-weight:900;
}
.site-brand span.brand-accent { color: #ff6a5b; }

.main-nav { display:flex; align-items:center; gap: 22px; }
.main-nav ul { list-style:none; margin:0; padding:0; display:flex; gap: 22px; }
.main-nav a { color:#1f3a4b; font-weight:600; font-size:.95rem; }
.main-nav a:hover { color: #ff6a5b; }

/* Dropdown */
.dropdown { position: relative; }
.dropdown-toggle {
    display:inline-flex;align-items:center;gap:6px;
    background: #fff; border: 1.5px solid #c6ece7;
    color:#0e5b55; padding: 8px 16px; border-radius: 999px;
    font-weight: 700; cursor: pointer; font-size: .95rem;
    transition: all .2s ease;
}
.dropdown-toggle:hover { background:#f1fbf9; }
.dropdown-toggle .caret { transition: transform .25s ease; }
.dropdown.open .dropdown-toggle .caret { transform: rotate(180deg); }

.dropdown-menu {
    position: absolute; right: 0; top: calc(100% + 10px);
    min-width: 260px; background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 50px -20px rgba(14,91,85,.25);
    padding: 10px; opacity: 0; pointer-events: none;
    transform: translateY(-6px);
    transition: opacity .2s ease, transform .2s ease;
    border: 1px solid #e3f5f1; max-height: 420px; overflow-y: auto;
}
.dropdown.open .dropdown-menu { opacity:1; pointer-events:auto; transform: translateY(0); }
.dropdown-menu a {
    display:flex;align-items:center;gap:10px;
    padding: 10px 12px; color:#1f3a4b;
    border-radius: 10px; font-weight: 600; font-size: .95rem;
}
.dropdown-menu a:hover { background: #f1fbf9; color:#0e5b55; }
.dropdown-menu .dot {
    width:8px;height:8px;border-radius:999px;
    background: linear-gradient(135deg,#ff8f6b,#0e5b55); display:inline-block;
}

.hamburger { display:none; background:none;border:0;cursor:pointer; padding:8px; }
.hamburger span { display:block; width:22px;height:2px;background:#1f3a4b; margin: 4px 0; border-radius:2px; }

/* =========================================================
   HERO
   ========================================================= */
.hero { padding: 70px 0 60px; position: relative; overflow: hidden; }
.hero-grid {
    display: grid; grid-template-columns: 1.1fr .9fr;
    gap: 40px; align-items: center;
}
.hero-eyebrow {
    display:inline-flex;align-items:center;gap:8px;
    padding: 6px 14px; background: #fff; border-radius: 999px;
    color:#0e5b55; font-weight:700; font-size:.8rem;
    letter-spacing:.08em; text-transform:uppercase;
    box-shadow: 0 10px 24px -16px rgba(14,91,85,.3);
}
.hero h1 { margin-top: 14px; }
.hero h1 .accent {
    background: linear-gradient(90deg,#ff6a5b,#0e5b55);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p.lead { font-size: 1.1rem; color:#4a6475; max-width: 540px; margin-bottom: 26px; }
.hero-ctas { display:flex; flex-wrap:wrap; gap: 14px; }
.hero-badges { display:flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-badge {
    display:inline-flex; align-items:center; gap: 8px;
    padding: 8px 14px; background:#fff; border-radius: 999px;
    font-size: .85rem; color:#0e5b55; font-weight:600;
    box-shadow: 0 10px 24px -18px rgba(14,91,85,.3);
}

.hero-collage {
    position: relative; aspect-ratio: 1 / 1;
    max-width: 460px; margin-left: auto;
}
.hero-card {
    position: absolute; border-radius: 24px;
    box-shadow: 0 30px 60px -24px rgba(14,91,85,.3);
    display:flex;align-items:flex-end; padding: 18px;
    color:#fff; font-weight:700; font-size: .95rem; overflow:hidden;
}
.hero-card::before {
    content:""; position:absolute; inset:0;
    background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,.45) 100%);
}
.hero-card span { position: relative; z-index: 1; }
.hero-card-1 { top:0; left:0; width:62%; height:62%; background: linear-gradient(135deg,#ffd3b8,#ff9e7a); }
.hero-card-2 { top: 8%; right:0; width:40%; height:40%; background: linear-gradient(135deg,#c6ece7,#5fc3b9); }
.hero-card-3 { bottom:0; left: 10%; width:40%; height:38%; background: linear-gradient(135deg,#fff2c4,#ffd56b); }
.hero-card-4 { bottom: 6%; right: 4%; width:48%; height:46%; background: linear-gradient(135deg,#bfe0f4,#6cb8dc); }

/* =========================================================
   SECTIONS
   ========================================================= */
.section { padding: 60px 0; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 40px; }
.section-eyebrow {
    display:inline-block;
    color:#0e5b55; font-weight:800; letter-spacing:.14em; text-transform:uppercase; font-size:.8rem;
    margin-bottom: 10px;
}
.section-head p { color:#4a6475; }

/* =========================================================
   CATEGORY GRID (8 categories)
   ========================================================= */
.cat-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
}
.cat-card {
    position: relative; display: block;
    background: #fff; border-radius: 20px;
    overflow: hidden; text-decoration: none; color: inherit;
    box-shadow: 0 20px 40px -24px rgba(14,91,85,.18);
    transition: transform .25s ease, box-shadow .25s ease;
    isolation: isolate;
}
.cat-card:hover { transform: translateY(-4px); box-shadow: 0 28px 50px -22px rgba(14,91,85,.3); color: inherit; }
.cat-art { aspect-ratio: 4 / 3; display:flex; align-items:center; justify-content:center; position:relative; overflow:hidden; }
.cat-art svg { width: 56%; height: auto; filter: drop-shadow(0 10px 18px rgba(0,0,0,.08)); }
.cat-body { padding: 14px 16px 18px; display:flex; align-items:center; justify-content:space-between; gap: 10px; }
.cat-body h3 { margin: 0; font-size: 1.02rem; }
.cat-body .cat-cta { color:#0e5b55; font-weight: 800; font-size: .95rem; }

/* category palettes */
.palette-coral  { background: linear-gradient(135deg,#ffdcc9,#ff9e7a); }
.palette-teal   { background: linear-gradient(135deg,#d2f1ef,#7fcfc5); }
.palette-sky    { background: linear-gradient(135deg,#dff0f8,#8fc5e3); }
.palette-sun    { background: linear-gradient(135deg,#fff2c4,#ffd56b); }
.palette-mint   { background: linear-gradient(135deg,#d9f3dd,#8cd79f); }
.palette-peach  { background: linear-gradient(135deg,#ffe4d1,#ffb589); }
.palette-rose   { background: linear-gradient(135deg,#ffd8d8,#ff9d9d); }
.palette-sand   { background: linear-gradient(135deg,#f6ecd9,#dec397); }

/* =========================================================
   HOMEPAGE ARTICLE
   ========================================================= */
.article-block {
    background: #fff; border-radius: 24px;
    padding: 42px clamp(22px, 4vw, 60px);
    box-shadow: 0 30px 60px -30px rgba(14,91,85,.18);
    border: 1px solid rgba(198, 236, 231, .5);
}
.article-block h2 { margin-top: 0; }
.article-block h3 { margin-top: 1.6em; color:#0e5b55; }
.article-block p, .article-block li { color: #253c4a; font-size: 1.02rem; }
.article-block ul, .article-block ol { padding-left: 1.2em; }
.article-block strong { color:#103141; }

/* =========================================================
   GUIDES / ARTICLE CARDS
   ========================================================= */
.guide-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px;
}
.guide-card {
    background: #fff; border-radius: 20px; padding: 24px;
    text-decoration: none; color: inherit;
    box-shadow: 0 20px 40px -24px rgba(14,91,85,.18);
    transition: transform .22s ease, box-shadow .22s ease;
    display:flex; flex-direction: column; gap: 12px;
    border: 1px solid #e3f5f1;
}
.guide-card:hover { transform: translateY(-3px); color:inherit; box-shadow: 0 28px 50px -22px rgba(14,91,85,.3); }
.guide-tag {
    display:inline-flex;align-items:center;
    padding: 4px 12px; border-radius: 999px;
    background: linear-gradient(135deg,#ffe4d1,#d2f1ef);
    color:#0e5b55;
    font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
    width: fit-content;
}
.guide-card h3 { font-size: 1.08rem; margin: 0; }
.guide-card p { margin: 0; color:#4a6475; font-size: .94rem; }
.guide-card .read-link {
    margin-top: auto; color:#ff6a5b; font-weight:800; font-size:.95rem;
    display:inline-flex; align-items:center; gap: 6px;
}

/* =========================================================
   CTA BAND
   ========================================================= */
.cta-band {
    margin-top: 40px; border-radius: 28px;
    padding: 42px clamp(22px, 4vw, 54px);
    background: linear-gradient(120deg,#ffb89b 0%, #7fcfc5 55%, #8fc5e3 100%);
    color: #103141;
    display:grid; grid-template-columns: 1.3fr 1fr; gap: 24px; align-items: center;
}
.cta-band h2 { color:#103141; margin: 0 0 .4em; }
.cta-band p { color:#253c4a; margin:0; }
.cta-band .cta-actions { display:flex; flex-wrap:wrap; gap: 12px; justify-content: flex-end; }

/* =========================================================
   SINGLE / PAGE
   ========================================================= */
.page-wrap { padding: 70px 0 90px; }
.page-grid { display:grid; grid-template-columns: 1fr 300px; gap: 40px; align-items: flex-start; }
.article-single {
    background:#fff; border-radius: 24px;
    padding: 44px clamp(22px, 4vw, 60px);
    box-shadow: 0 30px 60px -30px rgba(14,91,85,.18);
    border: 1px solid #e3f5f1;
}
.article-single h1 { margin-bottom: .4em; }
.article-single .meta { color:#0e5b55; font-weight:700; font-size:.85rem; letter-spacing:.08em; text-transform:uppercase; }
.article-single h2 { margin-top: 1.5em; color:#103141; }
.article-single h3 { margin-top: 1.3em; color:#0e5b55; }
.article-single p, .article-single li { color:#253c4a; font-size: 1.04rem; }

.sidebar {
    position: sticky; top: 90px;
    background:#fff; border-radius: 20px; padding: 22px;
    box-shadow: 0 20px 40px -24px rgba(14,91,85,.18);
    border: 1px solid #e3f5f1;
}
.sidebar h4 { margin: 0 0 14px; color:#103141; }
.sidebar ul { list-style: none; margin:0; padding:0; display:flex; flex-direction: column; gap: 2px; }
.sidebar li a {
    display:flex; align-items:center; gap:10px;
    padding: 10px 12px; border-radius: 10px; color:#1f3a4b; font-weight: 600; font-size: .95rem;
}
.sidebar li a:hover { background:#f1fbf9; color:#0e5b55; }
.sidebar .side-cta {
    margin-top: 16px; padding: 16px; border-radius: 16px;
    background: linear-gradient(135deg,#ffe4d1,#d2f1ef);
}
.sidebar .side-cta p { margin: 0 0 10px; font-weight:700; color:#0e5b55; }

.back-home {
    display:inline-flex; align-items:center; gap:6px;
    margin-top: 24px; color:#0e5b55; font-weight:800;
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
    margin-top: 60px; padding: 50px 0 30px;
    background: rgba(255,255,255,.6);
    border-top: 1px solid rgba(255, 106, 91, 0.08);
}
.footer-inner { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 36px; }
.footer-brand { max-width: 360px; color:#4a6475; }
.footer-col h5 { margin: 0 0 14px; color:#103141; font-size: 1rem; }
.footer-col ul { list-style:none; margin:0; padding:0; display:flex; flex-direction: column; gap: 8px; }
.footer-col a { color: #4a6475; font-weight: 500; }
.footer-col a:hover { color:#ff6a5b; }
.footer-bottom {
    margin-top: 36px; padding-top: 24px; border-top: 1px solid rgba(255, 106, 91, 0.1);
    display:flex; justify-content: space-between; align-items:center; gap: 20px;
    color:#6c7f8c; font-size: .9rem;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 980px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-collage { margin: 0 auto; }
    .cat-grid { grid-template-columns: repeat(3, 1fr); }
    .guide-grid { grid-template-columns: repeat(2, 1fr); }
    .page-grid { grid-template-columns: 1fr; }
    .cta-band { grid-template-columns: 1fr; }
    .cta-band .cta-actions { justify-content: flex-start; }
    .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 680px) {
    .main-nav ul { display:none; }
    .hamburger { display:block; }
    .main-nav.open ul {
        display:flex; flex-direction:column; position:absolute; top:100%; left:0; right:0;
        background:#fff; padding: 16px 20px; gap: 10px;
        box-shadow: 0 20px 40px -24px rgba(14,91,85,.2);
    }
    .cat-grid { grid-template-columns: repeat(2, 1fr); }
    .guide-grid { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr; }
    .hero { padding: 40px 0 30px; }
    .section { padding: 40px 0; }
    .footer-bottom { flex-direction: column; align-items: flex-start; }
}
