@import url('https://fonts.googleapis.com/css2?family=Lora:wght@600;700&family=Inter:wght@400;500;600;700&display=swap');

/* =============================================================
 * Phattify — hệ thiết kế gốc: Lora (serif tiêu đề) + Inter (thân),
 * tối giản đen–trắng, viền mảnh, nút pill đen, nhiều khoảng trắng.
 * Token lấy từ gcc-tokens.css của plugin (bản light).
 * ============================================================= */
:root {
  --bg: #ffffff; --card: #ffffff; --surface: #f7f7f7;
  --ink-strong: #1a1a1a; --ink: #333333; --muted: #6b6b6b; --ghost: #a0a0a0;
  --line: #dddddd; --line-faint: #eeeeee;
  --btn-bg: #1f1f1f; --btn-bg-hover: #000000; --btn-text: #ffffff;
  --radius: 12px; --pill: 100px;
  --shadow: 0 2px 8px rgba(0,0,0,.06); --shadow-hover: 0 6px 20px rgba(0,0,0,.12);
  --serif: 'Lora', Georgia, serif; --sans: 'Inter', -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
body {
  margin: 0; font: 15px/1.65 var(--sans); color: var(--ink); background: var(--bg); min-height: 100vh;
}
a { color: var(--ink-strong); }
h1, h2, h3 { font-family: var(--serif); color: var(--ink-strong); font-weight: 700; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 20px clamp(18px,4vw,40px) 90px; }
header.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 0; }
.brand { font-family: var(--serif); font-weight: 700; font-size: 26px; letter-spacing: -.3px; color: var(--ink-strong); }
.brand span { color: var(--ink-strong); }

.badge { background: #fff; border: 1px solid var(--line); padding: 6px 14px; border-radius: var(--pill); font-size: 12.5px; font-weight: 500; color: var(--muted); }
.badge b { color: var(--ink-strong); }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 24px; }
.card:hover { box-shadow: var(--shadow-hover); }
.grid { display: grid; gap: 16px; }
.cols-3 { grid-template-columns: repeat(3, 1fr); }
.cols-2 { grid-template-columns: 1fr 1fr; }
@media (max-width: 800px) { .cols-3, .cols-2 { grid-template-columns: 1fr; } }

h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin: 8px 0 4px; line-height: 1.15; }
.muted { color: var(--muted); }
label { display: block; font-size: 13px; font-weight: 600; color: var(--ink-strong); margin: 14px 0 6px; }
input, textarea, select {
  width: 100%; background: #fff; border: 1px solid var(--line); color: var(--ink);
  border-radius: 8px; padding: 12px 14px; font: inherit;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--ink-strong); }
textarea { min-height: 90px; resize: vertical; }

button, .btn {
  cursor: pointer; border: 0; border-radius: var(--pill); padding: 12px 28px; font: inherit; font-weight: 700;
  background: var(--btn-bg); color: var(--btn-text); transition: opacity .2s, background .2s;
  text-decoration: none; display: inline-block; font-size: 14.5px;
}
button:hover, .btn:hover { background: var(--btn-bg-hover); color: #fff; }
button.ghost, .btn.ghost { background: transparent; border: 1.5px solid var(--line); color: var(--ink-strong); }
button.ghost:hover, .btn.ghost:hover { background: var(--ink-strong); color: #fff; border-color: var(--ink-strong); }
button:disabled { opacity: .4; cursor: not-allowed; }
.btn.ic, button.ic { display: inline-flex; align-items: center; gap: 7px; }
.ic svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* =============================================================
 * Admin toolbar — layout chuẩn cho mọi bảng/thư viện
 * ============================================================= */
.tbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 0 14px; border-bottom: 1px solid var(--line-faint); margin-bottom: 14px; }
.tbar > * { margin: 0 !important; }
.tbar > .tbar-title { font-weight: 700; margin-right: 8px !important; display: inline-flex; align-items: center; gap: 6px; }
.tbar > .tbar-spacer { flex: 1; min-width: 0; }
/* Checkbox + label 1 khối liền */
.tbar .chk { display: inline-flex !important; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-strong); white-space: nowrap; cursor: pointer; font-weight: 600; padding: 6px 12px; border: 1px solid var(--line); border-radius: var(--pill); background: #fff; }
.tbar .chk:hover { border-color: var(--ink-strong); }
.tbar .chk input { width: 15px; height: 15px; margin: 0; cursor: pointer; accent-color: var(--ink-strong); }
.tbar .sel-count { font-size: 12.5px; color: var(--muted); white-space: nowrap; padding: 6px 12px; border-radius: var(--pill); background: var(--surface); border: 1px solid var(--line-faint); }
.tbar select, .tbar input[type="search"], .tbar input[type="text"] {
  width: auto; min-width: 130px; max-width: 200px; padding: 0 30px 0 12px; font-size: 13px; height: 34px;
  border-radius: var(--pill); background: #fff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat: no-repeat; background-position: right 12px center;
  -webkit-appearance: none; appearance: none;
}
.tbar input[type="search"], .tbar input[type="text"] { background-image: none; padding: 0 14px; }
.tbar .btn, .tbar button { padding: 0 18px; font-size: 13.5px; height: 36px; line-height: 1; border-radius: var(--pill); }
.tbar .divider { width: 1px; height: 20px; background: var(--line); }
@media (max-width: 640px) {
  .tbar select { min-width: 100%; max-width: 100%; flex: 1 0 100%; }
  .tbar .tbar-spacer { display: none; }
}

.pkg { text-align: center; position: relative; }
.pkg.popular { border-color: var(--ink-strong); border-width: 2px; }
.pkg .price { font-family: var(--serif); font-size: 40px; font-weight: 700; margin: 6px 0; color: var(--ink-strong); }
.pkg ul { list-style: none; padding: 0; margin: 14px 0; text-align: left; }
.pkg li { padding: 6px 0 6px 24px; position: relative; color: var(--muted); font-size: 14px; }
.pkg li::before { content: "✓"; color: var(--ink-strong); font-weight: 700; position: absolute; left: 0; }
.tag { position: absolute; top: -11px; right: 16px; background: var(--ink-strong); color: #fff; font-size: 10.5px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; padding: 4px 12px; border-radius: var(--pill); }

.toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); background: var(--ink-strong); color: #fff; padding: 12px 22px; border-radius: var(--pill); box-shadow: var(--shadow-hover); z-index: 100; font-size: 14px; }

/* Preview thiệp */
.preview { border-radius: 16px; padding: 32px; text-align: center; background: var(--surface); border: 1px solid var(--line); color: var(--ink); }
.preview img { max-width: 100%; border-radius: 10px; margin: 14px 0; }
.preview .p-title { font-family: var(--serif); font-size: 26px; font-weight: 700; color: var(--ink-strong); }
.preview .p-msg { white-space: pre-wrap; margin: 12px 0; }
.preview .p-sign { font-style: italic; color: var(--muted); }

.mediapick img { width: 100%; height: 84px; object-fit: cover; border-radius: 8px; cursor: pointer; border: 2px solid transparent; }
.mediapick img.sel, .mediachip.sel { border-color: var(--ink-strong); }
.mediachip { height: 84px; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 12px; text-align: center; background: var(--surface); border: 2px solid transparent; border-radius: 8px; cursor: pointer; color: var(--muted); padding: 4px; }

/* Wedding layout */
.preview .w-couple { font-family: var(--serif); font-size: 30px; font-weight: 700; color: var(--ink-strong); margin-bottom: 10px; }
.preview .w-couple span { color: var(--muted); margin: 0 6px; }
.preview .w-details { margin-top: 14px; font-size: 14px; color: var(--muted); display: flex; flex-direction: column; gap: 4px; }

.gcc-chat { margin-bottom: 8px; }
.ai-opts .ai-opt:hover { background: var(--surface); }

/* =============================================================
 * Landing (gcl-*) — port từ landing.css gốc (bỏ !important & var --gcc-*)
 * ============================================================= */
.gcl-nav { display: flex; align-items: center; gap: 28px; justify-content: flex-end; padding: 0 0 8px; flex-wrap: wrap; }
.gcl-nav a { color: var(--ink-strong); text-decoration: none; font-weight: 500; font-size: 14.5px; }
.gcl-nav a:hover { color: var(--muted); }

.gcl-hero { border: 1px solid var(--line); border-radius: 20px; padding: clamp(56px,8vw,96px) clamp(28px,5vw,80px); text-align: center; margin: 10px 0 clamp(56px,7vw,88px); }
.gcl-badge { display: inline-block; border: 1px solid var(--line); font-size: 11px; font-weight: 600; letter-spacing: 1.8px; text-transform: uppercase; padding: 5px 16px; border-radius: var(--pill); margin-bottom: 22px; color: var(--muted); }
.gcl-h1 { font-family: var(--serif); font-size: clamp(2rem,5.5vw,3.4rem); font-weight: 700; margin: 0 0 18px; line-height: 1.12; }
.gcl-sub { font-size: clamp(.95rem,2.2vw,1.1rem); color: var(--muted); max-width: 640px; margin: 0 auto 26px; line-height: 1.75; }
.gcl-pills { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-bottom: 36px; }
.gcl-pill { border: 1px solid var(--line); color: var(--muted); font-size: 12.5px; font-weight: 500; padding: 5px 14px; border-radius: var(--pill); }
.gcl-cta-row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.gcl-section { margin-bottom: 72px; }
.gcl-h2 { font-family: var(--serif); font-size: clamp(1.5rem,3.5vw,2.2rem); font-weight: 700; text-align: center; margin: 0 0 10px; line-height: 1.25; }
.gcl-lead { text-align: center; color: var(--muted); font-size: .98rem; max-width: 560px; margin: 0 auto 40px; line-height: 1.75; }

.gcl-types-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 40px; }
.gcl-type-card { border: 1px solid var(--line); border-radius: 16px; padding: 36px 28px; text-align: center; transition: box-shadow .2s; }
.gcl-type-card:hover { box-shadow: var(--shadow-hover); }
.gcl-type-card.wedding { border-style: dashed; }
.gcl-type-icon { font-size: 2.8rem; margin-bottom: 14px; display: block; }
.gcl-type-card h3 { font-size: 1.35rem; margin: 0 0 10px; }
.gcl-type-card p { color: var(--muted); font-size: .92rem; margin: 0 0 18px; line-height: 1.72; }
.gcl-tags { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.gcl-tag { border: 1px solid var(--line); color: var(--muted); font-size: 11px; font-weight: 600; padding: 3px 10px; border-radius: var(--pill); }
.gcl-tag.w { border-style: dashed; }

.gcl-feat-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.gcl-feat { border: 1px solid var(--line); border-radius: 14px; padding: 26px 20px; transition: box-shadow .2s; }
.gcl-feat:hover { box-shadow: var(--shadow-hover); }
.gcl-feat.dark { border-color: var(--ink-strong); }
.gcl-feat-icon { font-size: 1.9rem; margin-bottom: 12px; display: block; }
.gcl-feat h3 { font-size: 1rem; margin: 0 0 8px; line-height: 1.35; }
.gcl-feat p { color: var(--muted); font-size: .86rem; margin: 0; line-height: 1.7; }

.gcl-steps { display: flex; flex-direction: column; max-width: 720px; margin: 40px auto 0; }
.gcl-step { display: flex; gap: 22px; align-items: flex-start; padding: 26px 0; border-bottom: 1px solid var(--line-faint); }
.gcl-step:last-child { border-bottom: none; }
.gcl-step-n { width: 42px; height: 42px; flex-shrink: 0; margin-top: 2px; background: var(--ink-strong); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: var(--serif); font-weight: 700; font-size: 1rem; }
.gcl-step h3 { font-size: 1.05rem; margin: 0 0 5px; }
.gcl-step p { color: var(--muted); font-size: .9rem; margin: 0; line-height: 1.65; }

.gcl-cta { border: 1px solid var(--line); border-radius: 20px; padding: clamp(52px,7vw,80px) clamp(32px,5vw,72px); text-align: center; }
.gcl-cta h2 { font-family: var(--serif); font-size: clamp(1.55rem,4vw,2.3rem); font-weight: 700; margin: 0 0 14px; }
.gcl-cta p { color: var(--muted); font-size: .97rem; margin: 0 auto 6px; max-width: 520px; line-height: 1.72; }
.gcl-cta-btns { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 30px; }

/* landing buttons */
.gcl-btn-primary, .gcl-btn-dark { display: inline-block; background: var(--btn-bg); color: #fff; font-weight: 700; font-size: 15.5px; padding: 15px 40px; border-radius: var(--pill); text-decoration: none; transition: opacity .2s; }
.gcl-btn-primary:hover, .gcl-btn-dark:hover { opacity: .82; color: #fff; }
.gcl-btn-ghost, .gcl-btn-outline { display: inline-block; background: transparent; border: 1.5px solid var(--line); color: var(--ink-strong); font-weight: 700; font-size: 15px; padding: 13px 34px; border-radius: var(--pill); text-decoration: none; transition: all .2s; }
.gcl-btn-ghost:hover, .gcl-btn-outline:hover { border-color: var(--ink-strong); }

/* AI suggestions */
.gcl-ai-grid { display: flex; flex-direction: column; margin: 40px 0 28px; max-width: 720px; margin-left: auto; margin-right: auto; }
.gcl-ai-step { display: flex; gap: 20px; align-items: flex-start; padding: 24px 0; border-bottom: 1px solid var(--line-faint); }
.gcl-ai-step:last-child { border-bottom: none; }
.gcl-ai-num { width: 42px; height: 42px; flex-shrink: 0; background: var(--btn-bg); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: var(--serif); font-weight: 700; font-size: 1.1rem; margin-top: 2px; }
.gcl-ai-step h3 { font-size: 1.05rem; margin: 0 0 6px; }
.gcl-ai-step p { color: var(--muted); font-size: .9rem; margin: 0; line-height: 1.65; }
.gcl-ai-note { display: flex; gap: 16px; align-items: flex-start; border: 1px solid var(--line); border-radius: 14px; padding: 22px 24px; max-width: 720px; margin: 0 auto; }
.gcl-ai-note-icon { font-size: 1.6rem; flex-shrink: 0; margin-top: 2px; }
.gcl-ai-note p { color: var(--muted); font-size: .9rem; margin: 0; line-height: 1.7; }
.gcl-ai-note strong { color: var(--ink-strong); }
.gcl-ai-pill { display: inline-block; background: var(--btn-bg); color: #fff; font-size: 11px; font-weight: 700; padding: 2px 10px; border-radius: var(--pill); vertical-align: middle; margin-left: 6px; }

/* viewer tracking / notification */
.gcl-track-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; margin-top: 40px; }
.gcl-track-item { text-align: center; border: 1px solid var(--line); border-radius: 14px; padding: 26px 18px; transition: box-shadow .2s; }
.gcl-track-item:hover { box-shadow: var(--shadow-hover); }
.gcl-track-item .ti { font-size: 2rem; display: block; margin-bottom: 10px; }
.gcl-track-item h3 { font-size: .98rem; margin: 0 0 7px; }
.gcl-track-item p { color: var(--muted); font-size: .85rem; margin: 0; line-height: 1.65; }

/* theme callout */
.gcl-theme-callout { border: 1px solid var(--line); border-radius: 16px; padding: 28px; display: flex; align-items: center; gap: 22px; margin-bottom: 56px; }
.gcl-theme-dots { display: flex; gap: 7px; flex-shrink: 0; }
.gcl-dot { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line); }
.gcl-theme-text h3 { font-size: 1.1rem; margin: 0 0 5px; }
.gcl-theme-text p { color: var(--muted); font-size: .88rem; margin: 0; line-height: 1.7; }

/* security / privacy */
.gcl-security { border: 1px solid var(--line); border-radius: 20px; padding: clamp(48px,7vw,80px) clamp(28px,5vw,64px); margin-bottom: 72px; }
.gcl-priv-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 16px; margin-bottom: 20px; }
.gcl-priv-item { border: 1px solid var(--line); border-radius: 14px; padding: 26px 22px; transition: box-shadow .2s; }
.gcl-priv-item:hover { box-shadow: var(--shadow-hover); }
.gcl-priv-item .pi { font-size: 1.9rem; margin-bottom: 10px; display: block; }
.gcl-priv-item h3 { font-size: 1rem; margin: 0 0 7px; }
.gcl-priv-item p { color: var(--muted); font-size: .86rem; margin: 0; line-height: 1.7; }
.gcl-priv-note { border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px; }
.gcl-priv-note p { color: var(--muted); font-size: .9rem; margin: 0; }
.gcl-priv-note strong, .gcl-feat p strong, .gcl-step p strong { color: var(--ink-strong); }

@media (max-width: 900px) { .gcl-feat-grid, .gcl-track-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 800px) { .gcl-types-grid, .gcl-priv-grid { grid-template-columns: 1fr; } .gcl-theme-callout { flex-direction: column; align-items: flex-start; } }
@media (max-width: 500px) { .gcl-feat-grid, .gcl-track-grid { grid-template-columns: 1fr; } }

footer .fnav { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }

/* Dark theme (toggle) */
:root[data-theme="dark"] {
  --bg: #141414; --card: #1a1a1a; --surface: #1f1f1f;
  --ink-strong: #f4f4f4; --ink: #e4e4e4; --muted: #a0a0a0; --ghost: #6b6b6b;
  --line: #2a2a2a; --line-faint: #1f1f1f; --btn-bg: #e4e4e4; --btn-bg-hover: #ffffff; --btn-text: #141414;
}
:root[data-theme="dark"] input, :root[data-theme="dark"] textarea, :root[data-theme="dark"] select { background: #1f1f1f; }
