﻿:root {
    /* 隤輯?歹??渡隞??蝘???瘛梢???*/
    --primary: #3b82f6;
    --primary-dark: #2563eb;
    --primary-light: #eff6ff;
    --accent: #0ea5e9;
    /* 鈭株??脤?蝬?*/
    --accent-gradient: linear-gradient(135deg, #3b82f6 0%, #0ea5e9 100%);

    --bg: #f8fafc;
    --bg-surface: rgba(255, 255, 255, 0.7);
    /* ?餌??祆?? */
    --bg-card: #ffffff;

    --text-main: #0f172a;
    /* 敺楛??暺?瘥?暺?釭??*/
    --text-sub: #475569;
    --text-muted: #94a3b8;

    --border: rgba(226, 232, 240, 0.8);
    --border-hover: #cbd5e1;

    /* ?啣蔣蝟餌絞 */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.02);
    --shadow-glow: 0 20px 40px -10px rgba(59, 130, 246, 0.15);

    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 8px;

    --font-sans: 'Noto Sans TC', system-ui, -apple-system, sans-serif;
}

/* Base Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--font-sans);
    background-color: var(--bg);
    /* 憓??蝝?嚗?釭??*/
    background-image:
        radial-gradient(at 0% 0%, hsla(215, 98%, 61%, 0.1) 0px, transparent 50%),
        radial-gradient(at 100% 0%, hsla(256, 100%, 60%, 0.08) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.intro-splash {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    animation: splash-fade-out 1s ease 1.5s forwards;
}

.intro-splash-inner {
    position: relative;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}

.intro-splash-inner picture {
    display: block;
    width: 100%;
    height: 100%;
}

.intro-splash-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.intro-splash-line-en {
    position: absolute;
    left: 50%;
    bottom: 150px;
    transform: translateX(-50%);
    margin: 0;
    width: calc(100% - 32px);
    font-size: clamp(29px, 4.2vw, 47px);
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.02em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
    z-index: 1;
    text-align: center;
    font-family: system-ui, -apple-system, "Segoe UI", "PingFang TC", "Microsoft JhengHei", sans-serif;
}

.intro-splash-line-zh {
    position: absolute;
    left: 50%;
    bottom: 82px;
    transform: translateX(-50%);
    margin: 0;
    width: calc(100% - 32px);
    font-size: clamp(38px, 5vw, 55px);
    font-weight: 500;
    color: #ffffff;
    letter-spacing: 0.01em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
    z-index: 1;
    text-align: center;
    font-family: system-ui, -apple-system, "Segoe UI", "PingFang TC", "Microsoft JhengHei", sans-serif;
}

@keyframes splash-fade-out {
    to {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    }
}

/* Header */
.header {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 6vw;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    transition: all 0.3s ease;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* 閮剖?logo-mark?祝摨衣5% */
.logo-mark {
    width: 60px;
    height: auto;
    object-fit: contain;
    object-position: center;
    display: inline-block;
    /* border-radius: 50%; */
}

.logo-mark img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    /* border-radius: 50%; */
}

.logo-name {
    font-weight: 700;
    font-size: 20px;
    color: var(--text-main);
    letter-spacing: 0.02em;
}

.logo-sub {
    font-size: 15px;
    color: var(--text-muted);
    font-weight: 500;
}

.nav {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-toggle {
    display: none;
}

.nav-link {
    font-size: 18px;
    font-weight: 500;
    color: var(--text-sub);
    text-decoration: none;
    transition: color 0.2s;
    position: relative;
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
    border-radius: 2px;
}

.nav-link:hover::after {
    width: 100%;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    letter-spacing: 0.02em;
    border: none;
}

.btn.primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 8px 20px -4px rgba(59, 130, 246, 0.4);
}

.btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px -4px rgba(59, 130, 246, 0.5);
}

.btn.outline {
    background: white;
    color: var(--text-main);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.btn.outline:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-light);
}

/* Hero Section */
.hero {
    position: relative;
    padding: 100px 6vw 60px;
    overflow: hidden;
}

/* 憓?銝??憌暹抒??? */
.hero-bg-blob {
    position: absolute;
    top: -10%;
    right: -5%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, rgba(255, 255, 255, 0) 70%);
    z-index: -1;
    pointer-events: none;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-kicker {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary-light);
    border-radius: 20px;
}

.hero h1 {
    font-size: clamp(36px, 4.5vw, 52px);
    line-height: 1.2;
    margin: 0 0 24px;
    font-weight: 800;
    color: var(--text-main);
}

.hero-highlight {
    background: -webkit-linear-gradient(315deg, var(--primary-dark), var(--accent));
    background: linear-gradient(315deg, var(--primary-dark), var(--accent));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-sub);
    margin-bottom: 32px;
    max-width: 540px;
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.badge {
    padding: 6px 12px;
    background: white;
    border: 1px solid var(--border);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-sub);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Card General Styling */
.card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s, box-shadow 0.3s;
}

/* Hero Panel Specific */
.hero-panel {
    padding: 24px 28px;
    background: rgba(255, 255, 255, 0.9);
}

.hero-panel-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 12px;
}

.hp-title {
    font-weight: 700;
    color: var(--text-main);
    font-size: 15px;
}

.hp-dots span {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: var(--border);
    border-radius: 50%;
    margin-left: 4px;
}

.hero-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.hero-list li {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.icon-box {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}

.icon-box.sm {
    width: 32px;
    height: 32px;
}

.icon-box.green {
    background: #dcfce7;
    color: #16a34a;
}

.icon-box.blue {
    background: #dbeafe;
    color: #2563eb;
}

.icon-box.yellow {
    background: #fef9c3;
    color: #ca8a04;
}

.list-title {
    font-weight: 700;
    font-size: 15px;
    color: var(--text-main);
    margin-bottom: 4px;
}

.list-desc {
    font-size: 14px;
    color: var(--text-sub);
    line-height: 1.5;
}

/* Sections */
.section {
    padding: 80px 6vw;
}

.section-alt {
    background: linear-gradient(to bottom, #f1f5f9, #f8fafc);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 60px;
}

.section-header h2 {
    font-size: 32px;
    font-weight: 800;
    margin: 0 0 16px;
    color: var(--text-main);
}

.section-header p {
    font-size: 18px;
    color: var(--text-sub);
}

/* About */
.about-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 60px;
    align-items: start;
}

.about-main p {
    font-size: 16px;
    margin-bottom: 24px;
    color: var(--text-sub);
}

.about-main strong {
    color: var(--primary-dark);
    background: linear-gradient(120deg, transparent 60%, rgba(59, 130, 246, 0.2) 60%);
}

.about-list {
    padding-left: 20px;
    line-height: 1.8;
    color: var(--text-sub);
}

.about-list li {
    margin-bottom: 8px;
}

.about-side {
    padding: 32px;
    background: white;
    border: 1px solid var(--border);
}

.about-side h3 {
    margin-top: 0;
    font-size: 20px;
}

.about-tags {
    padding-left: 20px;
    color: var(--text-sub);
    line-height: 1.8;
}

/* Services */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.service {
    padding: 32px;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: white;
    border: 1px solid transparent;
}

.service:hover {
    border-color: var(--primary-light);
    box-shadow: var(--shadow-glow);
    transform: translateY(-5px);
}

.service-icon {
    font-size: 32px;
    margin-bottom: 20px;
}

.service h3 {
    font-size: 20px;
    margin: 0 0 12px;
    font-weight: 700;
}

.service-desc {
    font-size: 15px;
    color: var(--text-sub);
    flex-grow: 1;
}

.service ul {
    margin: 0;
    padding-left: 20px;
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Cases */
.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    align-items: stretch;
}

.case {
    padding: 32px;
    background: white;
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 320px;
}

.case-feature {
    border: 2px solid var(--primary-light);
    background: linear-gradient(to bottom right, white, #f8fafc);
}

.case-badge {
    position: absolute;
    top: 8px;
    right: 16px;
    background: var(--primary);
    color: white;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 600;
    z-index: 1;
}

.case h3 {
    font-size: 22px;
    margin: 0 0 8px;
    color: var(--text-main);
}

.case-subtitle {
    color: var(--primary);
    font-weight: 500;
    font-size: 15px;
    margin-bottom: 16px;
}

.case-summary {
    color: var(--text-sub);
    font-size: 15px;
    margin: 0 0 18px;
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: calc(1.7em * 4);
}

.case-open-btn {
    margin-top: auto;
    width: 100%;
}

.case-modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: none;
    padding: 12px;
    box-sizing: border-box;
}

.case-modal.open {
    display: block;
}

.case-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
}

.case-modal-dialog {
    position: relative;
    width: min(760px, 100%);
    height: min(860px, calc(100dvh - 24px));
    max-height: calc(100dvh - 24px);
    margin: 0 auto;
    background: #fff;
    border-radius: 18px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.case-modal-content {
    padding: 28px;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
    padding-bottom: max(28px, env(safe-area-inset-bottom));
}

.case-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: #f1f5f9;
    color: #0f172a;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.modal-badge {
    position: static;
    display: inline-block;
    margin-bottom: 14px;
}

.modal-block {
    margin-top: 16px;
}

.modal-block h4 {
    margin: 0 0 8px;
    font-size: 16px;
    color: var(--text-main);
}

.case-list {
    margin: 0;
    padding-left: 18px;
    color: var(--text-sub);
}

body.modal-open {
    overflow: hidden;
}

@supports not (height: 100dvh) {
    .case-modal-dialog {
        height: min(860px, calc(100vh - 24px));
        max-height: calc(100vh - 24px);
    }
}

/* Process */
.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.step {
    padding: 32px;
    position: relative;
    overflow: hidden;
}

.step-number {
    font-size: 48px;
    font-weight: 900;
    color: rgba(59, 130, 246, 0.1);
    position: absolute;
    top: 10px;
    right: 20px;
    line-height: 1;
}

.step h3 {
    position: relative;
    font-size: 18px;
    margin-bottom: 12px;
    z-index: 1;
}

.step p {
    position: relative;
    z-index: 1;
    font-size: 15px;
}

/* ======================================= */
/* ?舐窗??(Contact) ?憛?見撘?- 靽格迤?箔?甈?*/
/* ======================================= */

.contact-grid {
    display: grid;
    /* 靽格迤?箏像??銝?雿? */
    grid-template-columns: repeat(3, 1fr);
    gap: 20px; /* 蝮桀???霈?甈?游末? */
}

/* 蝣箔????????折?頝?*/
.contact-card,
.prep-card,
.tip-card {
    padding: 30px 25px; /* ?亙凝蝮桀??折?頝誑?拇?銝? */
    display: flex;
    flex-direction: column;
}

/* ?舐窗皜 (Contact List) */
.contact-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.contact-list li {
    display: flex;
    align-items: center;
    margin-bottom: 8px; /* ?亙凝蝮桀?銵? */
    font-size: 15px;
}
.contact-label {
    width: 70px; /* ?亙凝蝮桀?璅惜撖砍漲 */
    font-weight: 500;
    color: var(--text-sub);
}
.contact-list a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

/* 皞?皜 (Preparation List) - ?其葉?? */
.prep-note {
    margin-top: 10px;
    padding-bottom: 10px;
    margin-bottom: 10px;
}
.prep-card h3,
.tip-card h3 {
    font-size: 18px;
    color: var(--primary-strong);
    margin-bottom: 12px;
}

.prep-list {
    list-style: none;
    padding-left: 0;
    margin: 0;
    font-size: 14px; /* ?亙凝蝮桀?摮? */
    color: var(--text-main);
    line-height: 1.7;
}

.prep-list li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 6px;
    font-weight: 500;
}

.prep-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    font-size: 12px;
    top: 2px;
    opacity: 0.7;
}

.prep-summary {
    font-size: 13px;
    color: var(--text-sub);
    margin-top: 15px;
}

/* ??蝭??憛?(Example Tip Content) - ?典?游? */
.tip-card p {
    font-size: 14px;
    color: var(--text-sub);
}

.contact-examples {
    list-style: none;
    padding-left: 0;
    margin: 16px 0;
}

.contact-examples li {
    font-size: 14px;
    color: var(--text-main);
    padding: 8px 10px;
    background: var(--primary-soft);
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
    border: 1px solid rgba(43, 124, 255, 0.2);
    font-weight: 500;
}

/* RWD 隤踵 */
@media (max-width: 1200px) {
    .contact-grid {
        /* 銝剖偕撖貉撟?(憒之撟單??蝑) 閮剔?拇? */
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .contact-grid {
        /* 銵?鋆蔭閮剔銝甈?*/
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

/* Footer */
.footer {
    padding: 40px 6vw;
    text-align: center;
    background: white;
    border-top: 1px solid var(--border);
    font-size: 14px;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.footer-link {
    color: var(--text-sub);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.footer-link:hover {
    color: var(--primary);
}

/* 隱私權政策等法律頁 */
.legal-page {
    padding-top: 48px;
    padding-bottom: 80px;
}

.legal-header h1 {
    font-size: clamp(28px, 4vw, 36px);
    font-weight: 800;
    margin: 0 0 12px;
    color: var(--text-main);
}

.legal-updated {
    font-size: 14px;
    color: var(--text-muted);
    margin: 0;
}

.legal-content {
    max-width: 720px;
    margin: 0 auto;
    padding: 36px 32px 40px;
    text-align: left;
    background: rgba(255, 255, 255, 0.95);
}

.legal-content > p,
.legal-content > ul {
    font-size: 15px;
    color: var(--text-sub);
    line-height: 1.8;
    margin: 0 0 1.25em;
}

.legal-content h2 {
    font-size: 17px;
    font-weight: 700;
    color: var(--text-main);
    margin: 2em 0 0.65em;
}

.legal-content h2:first-of-type {
    margin-top: 0.5em;
}

.legal-content ul {
    padding-left: 1.35em;
}

.legal-content li {
    margin-bottom: 0.5em;
}

.legal-content li:last-child {
    margin-bottom: 0;
}

.logo-link {
    text-decoration: none;
    color: inherit;
}

.logo-link:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 4px;
    border-radius: var(--radius-sm);
}

@media (max-width: 768px) {
    .legal-content {
        padding: 28px 20px 32px;
    }
}

/* ???? */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--accent-gradient);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px -4px rgba(59, 130, 246, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 40;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px -4px rgba(59, 130, 246, 0.5);
}

.back-to-top:active {
    transform: translateY(-1px);
}

/* ?踵?撘?撠撟矽?湔???蝵?*/
@media (max-width: 768px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
}

/* Animations & Responsive */
.js .reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.5, 0, 0, 1);
}

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

@media (max-width: 768px) {
    .header {
        padding: 10px 20px;
    }

    .nav {
        position: fixed;
        top: 60px;
        right: 20px;
        width: 200px;
        background: white;
        flex-direction: column;
        padding: 20px;
        box-shadow: var(--shadow-lg);
        border-radius: 12px;
        display: none;
    }

    .nav.open {
        display: flex;
    }

    .nav-toggle {
        display: flex;
        flex-direction: column;
        gap: 5px;
        background: none;
        border: none;
    }

    .nav-toggle span {
        width: 24px;
        height: 2px;
        background: var(--text-main);
    }

    .hero {
        padding-top: 40px;
    }

    .hero-inner,
    .about-grid,
    .contact-grid,
    .cases-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .hero h1 {
        font-size: 32px;
    }

    .hero-panel {
        order: -1;
        margin-bottom: 20px;
    }

    .case {
        padding: 24px;
        min-height: 280px;
    }

    .case-badge {
        top: 5px;
        right: 12px;
        font-size: 11px;
        padding: 3px 8px;
    }

    .case-modal-content {
        padding: 22px 18px;
    }

    .case-modal {
        padding: 8px;
    }

    .case-modal-dialog {
        width: 100%;
        height: calc(100dvh - 16px);
        max-height: calc(100dvh - 16px);
        border-radius: 14px;
    }

    @supports not (height: 100dvh) {
        .case-modal-dialog {
            height: calc(100vh - 16px);
            max-height: calc(100vh - 16px);
        }
    }
}
