/*
Theme Name: Hello Elementor Child
Description: 基於 Hello Elementor
Template: hello-elementor
Version: 1.0.0
Text Domain: hello-elementor-child
*/
@import url("../hello-elementor/style.css");

/* ===== :root 顏色系統 ===== */
:root {
    --gd-primary: #1a73e8;
    --gd-secondary: #0d47a1;
    --gd-accent: #34c759;
    --gd-bg: #f8faff;
    --gd-text: #2d3748;
    --gd-white: #ffffff;
    --gd-gray: #94a3b8;
    --gd-border: #e2e8f0;
    --gd-light-bg: #f1f5f9;
    --gd-success-bg: #ecfdf5;
}

/* ===== 通用容器 ===== */
.gd-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* ===== Home Page Layout（完全保留）===== */
.gd-home-wrapper {
    width: 100%;
    padding: 3rem 1rem;
    margin: 0 auto;
}
.gd-hero-wrapper   { background: linear-gradient(135deg, #0d47a1, #1a73e8); color: white; }
.gd-about-wrapper  { background: #ffffff; }
.gd-cat-wrapper    { background: #f1f5f9; }
.gd-posts-wrapper  { background: #ffffff; }
.gd-tips-wrapper   { background: #ecfdf5; }
.gd-cta-wrapper    { background: linear-gradient(135deg, #0d47a1, #1a73e8); color: white; }
.gd-home-wrapper > section { max-width: 1200px; margin: 0 auto; }

.gd-hero-section { display: flex; align-items: center; padding: 2rem 0; }
.gd-hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.gd-hero-left { display: flex; flex-direction: column; gap: 1.2rem; }
.gd-hero-doctor-img { width: 160px; height: 160px; border-radius: 50%; border: 5px solid rgba(255,255,255,0.3); box-shadow: 0 8px 25px rgba(0,0,0,0.3); object-fit: cover; }
.gd-hero-title { font-size: 2.8rem; font-weight: 800; margin: 0; text-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.gd-hero-subtitle { font-size: 1.25rem; opacity: 0.9; margin: 0; }
.gd-cta-btn { background: var(--gd-accent); color: white; padding: 0.9rem 2.2rem; border-radius: 50px; font-weight: 600; text-decoration: none; align-self: flex-start; box-shadow: 0 6px 20px rgba(52,199,89,0.4); transition: all 0.3s ease; }
.gd-cta-btn:hover { transform: translateY(-3px); background: #2bab4e; }

.gd-hero-right { display: flex; justify-content: center; }
.gd-hero-post-card { background: var(--gd-white); border-radius: 16px; overflow: hidden; max-width: 460px; box-shadow: 0 10px 30px rgba(0,0,0,0.15); transition: transform 0.3s ease; }
.gd-hero-post-card:hover { transform: translateY(-6px); }
.gd-hero-post-thumb { width: 100%; height: 170px; object-fit: cover; }
.gd-hero-post-content { padding: 1.5rem; color: var(--gd-text); }
.gd-hero-post-label { display: block; font-size: 0.8rem; color: var(--gd-accent); text-transform: uppercase; letter-spacing: 1px; font-weight: 600; margin-bottom: 0.5rem; }
.gd-hero-post-title a { color: var(--gd-secondary); text-decoration: none; font-size: 1.35rem; font-weight: 700; line-height: 1.3; display: block; margin-bottom: 0.7rem; }
.gd-hero-post-title a:hover { color: var(--gd-primary); }
.gd-hero-post-excerpt { font-size: 0.95rem; color: #555; margin-bottom: 1rem; line-height: 1.5; }
.gd-hero-read-more { color: var(--gd-primary); font-weight: 600; text-decoration: none; font-size: 0.95rem; }
.gd-hero-read-more:hover { text-decoration: underline; }

.gd-about-doctor { display: flex; align-items: center; gap: 2.5rem; background: white; padding: 2.5rem; border-radius: 18px; box-shadow: 0 8px 25px rgba(0,0,0,0.08); }
.gd-doctor-avatar img { width: 110px; height: 110px; border-radius: 50%; object-fit: cover; border: 4px solid var(--gd-primary); }
.gd-doctor-name { font-size: 1.9rem; color: var(--gd-secondary); margin: 0 0 0.5rem; font-weight: 700; }
.gd-doctor-bio { margin: 0 0 1rem; color: #4b5563; line-height: 1.6; font-size: 1rem; }
.gd-btn-outline { display: inline-block; padding: 0.7rem 1.6rem; border: 2px solid var(--gd-primary); color: var(--gd-primary); border-radius: 8px; text-decoration: none; font-weight: 600; transition: 0.3s; }
.gd-btn-outline:hover { background: var(--gd-primary); color: white; }

.gd-section-title { text-align: center; font-size: 2.2rem; color: var(--gd-secondary); margin: 0 0 2rem; font-weight: 700; }
.gd-section-title::after { content: ''; width: 80px; height: 4px; background: var(--gd-accent); display: block; margin: 0.8rem auto 0; border-radius: 2px; }

.gd-categories-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 1.5rem; }
.gd-cat-card { background: white; padding: 1.5rem; border-radius: 12px; text-align: center; box-shadow: 0 4px 15px rgba(0,0,0,0.06); transition: 0.3s; text-decoration: none; color: var(--gd-text); }
.gd-cat-card:hover { transform: translateY(-5px); }
.gd-cat-name { font-weight: 600; font-size: 1.1rem; color: var(--gd-secondary); display: block; margin-bottom: 0.5rem; }
.gd-cat-count { font-size: 0.9rem; color: var(--gd-gray); }

.gd-posts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 2rem; }
.gd-post-card { background: white; border-radius: 16px; overflow: hidden; box-shadow: 0 6px 20px rgba(0,0,0,0.08); transition: 0.3s; display: flex; flex-direction: column; }
.gd-post-card:hover { transform: translateY(-10px); }
.gd-post-thumb img { width: 100%; height: 200px; object-fit: cover; transition: transform 0.4s ease; }
.gd-post-card:hover .gd-post-thumb img { transform: scale(1.05); }
.gd-post-content { padding: 1.5rem; flex-grow: 1; display: flex; flex-direction: column; }
.gd-post-title a { color: var(--gd-secondary); font-weight: 600; font-size: 1.25rem; text-decoration: none; line-height: 1.4; display: block; margin-bottom: 0.5rem; }
.gd-post-title a:hover { color: var(--gd-primary); }
.gd-post-excerpt { color: #555; font-size: 0.95rem; line-height: 1.6; margin-bottom: 1rem; flex-grow: 1; }
.gd-post-meta { font-size: 0.85rem; color: var(--gd-gray); margin-bottom: 1rem; display: flex; justify-content: space-between; }
.gd-post-cats a { color: var(--gd-primary); text-decoration: none; }
.gd-read-more { align-self: flex-start; color: var(--gd-accent); font-weight: 600; text-decoration: none; font-size: 0.95rem; margin-top: auto; }
.gd-read-more:hover { text-decoration: underline; }

.gd-tips-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.5rem; }
.gd-tip-item { background: white; padding: 2rem; border-radius: 14px; text-align: center; box-shadow: 0 4px 15px rgba(0,0,0,0.06); transition: transform 0.3s ease; }
.gd-tip-item:hover { transform: translateY(-5px); }
.gd-tip-icon { font-size: 2.5rem; margin-bottom: 1rem; color: var(--gd-accent); }
.gd-tip-item p { font-size: 1rem; line-height: 1.6; color: #374151; }
.gd-tip-item strong { color: var(--gd-secondary); }

.gd-contact-cta { text-align: center; padding: 3rem 2rem; }
.gd-cta-title { font-size: 2.3rem; margin-bottom: 1rem; font-weight: 700; }
.gd-cta-text { font-size: 1.2rem; opacity: 0.9; margin-bottom: 2rem; max-width: 600px; margin-left: auto; margin-right: auto; }
.gd-cta-big-btn { background: var(--gd-accent); color: white; padding: 1rem 2.5rem; border-radius: 50px; font-size: 1.1rem; font-weight: 600; text-decoration: none; box-shadow: 0 10px 25px rgba(52,199,89,0.4); transition: all 0.3s ease; }
.gd-cta-big-btn:hover { transform: translateY(-3px); background: #2bab4e; }

/* ===== ARCHIVE BANNER (第一篇做頁頂，無陰影) ===== */
.gd-archive-banner-wrapper {
    background: var(--gd-bg);
    padding: 0;
}
.gd-archive-banner {
    background: linear-gradient(135deg, var(--gd-primary), var(--gd-secondary));
    color: white;
    border-radius: 0;
    overflow: hidden;
    box-shadow: none !important;
}
.gd-banner-grid {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 0;
    align-items: center;
}
.gd-banner-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.gd-banner-content {
    padding: 3rem 2.5rem;
}
.gd-banner-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    opacity: 0.9;
}
.gd-banner-cat a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
}
.gd-banner-date {
    font-weight: 500;
}
.gd-banner-title {
    font-size: 2.4rem;
    font-weight: 800;
    margin: 0 0 1rem;
    line-height: 1.3;
}
.gd-banner-title a {
    color: white;
    text-decoration: none;
}
.gd-banner-title a:hover {
    text-decoration: underline;
}
.gd-banner-excerpt {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    opacity: 0.95;
}
.gd-banner-btn {
    background: var(--gd-accent);
    color: white;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    box-shadow: 0 6px 20px rgba(52,199,89,0.4);
    transition: all 0.3s ease;
}
.gd-banner-btn:hover {
    transform: translateY(-2px);
    background: #2bab4e;
}

/* ===== 之後文章：每行 3 個 ===== */
.gd-archive-posts-wrapper {
    background: var(--gd-bg);
    padding: 3rem 0;
}
.gd-archive-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}
.gd-grid-post {
    background: var(--gd-white);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}
.gd-grid-post:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 35px rgba(0,0,0,0.14);
}
.gd-grid-post .gd-post-thumb img,
.gd-grid-post .gd-placeholder-img {
    height: 180px;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.gd-grid-post:hover .gd-post-thumb img {
    transform: scale(1.05);
}
.gd-grid-post .gd-post-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.gd-grid-post .gd-post-title {
    font-size: 1.25rem;
    margin-bottom: 0.6rem;
}
.gd-grid-post .gd-post-title a {
    color: var(--gd-secondary);
    text-decoration: none;
}
.gd-grid-post .gd-post-title a:hover {
    color: var(--gd-primary);
}
.gd-grid-post .gd-post-excerpt {
    font-size: 0.95rem;
    margin-bottom: 1rem;
    flex-grow: 1;
}
.gd-grid-post .gd-post-meta {
    margin-bottom: 0.8rem;
    font-size: 0.88rem;
}
.gd-grid-post .gd-read-more {
    margin-top: auto;
    font-size: 0.95rem;
}

/* Placeholder */
.gd-placeholder-img {
    background: linear-gradient(135deg, #e0f2fe, #bae6fd);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gd-primary);
    font-weight: 600;
    font-size: 1rem;
}

/* 分頁 */
.gd-pagination {
    text-align: center;
    margin-top: 2rem;
}
.gd-pagination a,
.gd-pagination span {
    display: inline-block;
    min-width: 44px;
    height: 44px;
    line-height: 44px;
    margin: 0 6px;
    border-radius: 50%;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}
.gd-pagination a {
    background: var(--gd-white);
    color: var(--gd-text);
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}
.gd-pagination a:hover {
    background: var(--gd-primary);
    color: white;
    transform: translateY(-2px);
}
.gd-pagination .current {
    background: var(--gd-primary);
    color: white;
}

/* 無文章 */
.gd-no-posts {
    text-align: center;
    padding: 3rem;
    color: #666;
    font-style: italic;
    font-size: 1.1rem;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
    .gd-hero-grid { grid-template-columns: 1fr; text-align: center; gap: 2rem; }
    .gd-hero-left { align-items: center; }
    .gd-about-doctor { flex-direction: column; text-align: center; }
    .gd-banner-grid { grid-template-columns: 1fr; }
    .gd-banner-thumb img { height: 300px; }
    .gd-archive-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .gd-hero-doctor-img, .gd-doctor-avatar img { width: 130px; height: 130px; }
    .gd-hero-title { font-size: 2.3rem; }
    .gd-hero-section { padding: 1.5rem 0; }
    .gd-banner-title { font-size: 2rem; }
    .gd-banner-content { padding: 2rem; }
    .gd-archive-grid { grid-template-columns: 1fr; }
    .gd-categories-grid, .gd-posts-grid, .gd-tips-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .gd-home-wrapper, .gd-archive-posts-wrapper {
        padding: 2rem 0;
    }
    .gd-post-thumb img, .gd-placeholder-img { height: 160px !important; }
    .gd-hero-doctor-img, .gd-doctor-avatar img { width: 110px; height: 110px; }
    .gd-banner-title { font-size: 1.8rem; }
}



/* ===== SINGLE PAGE LAYOUT ===== */
.gd-single-wrapper {
    background: var(--gd-bg);
    padding: 3rem 0;
}
.gd-single-article {
    background: var(--gd-white);
    padding: 2.5rem;
    border-radius: 18px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.06);
    max-width: 900px;
    margin: 0 auto;
}
.gd-single-header {
    margin-bottom: 2rem;
    text-align: center;
}
.gd-single-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--gd-gray);
}
.gd-cat-badge {
    background: var(--gd-accent);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.8rem;
}
.gd-single-title {
    font-size: 2.4rem;
    color: var(--gd-secondary);
    margin: 0;
    font-weight: 800;
    line-height: 1.3;
}
.gd-single-thumb {
    margin: 2rem 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}
.gd-single-thumb img {
    width: 100%;
    height: auto;
    display: block;
}
.gd-single-content {
    font-size: 1.1rem;
    line-height: 1.85;
    color: #2d3748;
}
.gd-single-content p {
    margin-bottom: 1.6rem;
}
.gd-single-content h2,
.gd-single-content h3,
.gd-single-content h4 {
    color: var(--gd-secondary);
    margin: 2rem 0 1rem;
    font-weight: 700;
}
.gd-single-tags {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--gd-border);
    text-align: center;
}
.gd-tag {
    display: inline-block;
    background: var(--gd-light-bg);
    color: var(--gd-primary);
    padding: 0.4rem 0.9rem;
    border-radius: 6px;
    font-size: 0.9rem;
    margin: 0 0.4rem 0.6rem;
}

/* 相關文章：同 Archive 3 欄 */
.gd-related-section {
    background: var(--gd-bg);
    padding: 3rem 0;
}
.gd-related-title {
    text-align: center;
    font-size: 2rem;
    color: var(--gd-secondary);
    margin: 0 0 2rem;
    font-weight: 700;
}
.gd-related-title::after {
    content: '';
    width: 80px;
    height: 4px;
    background: var(--gd-accent);
    display: block;
    margin: 0.8rem auto 0;
    border-radius: 2px;
}

/* 共用 Archive 3 欄樣式 */
.gd-archive-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}
.gd-grid-post {
    background: var(--gd-white);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}
.gd-grid-post:hover {
    transform: translateY(-8px);
}
.gd-grid-post .gd-post-thumb img,
.gd-grid-post .gd-placeholder-img {
    height: 180px;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.gd-grid-post:hover .gd-post-thumb img {
    transform: scale(1.05);
}
.gd-grid-post .gd-post-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.gd-grid-post .gd-post-title {
    font-size: 1.25rem;
    margin-bottom: 0.6rem;
}
.gd-grid-post .gd-post-title a {
    color: var(--gd-secondary);
    text-decoration: none;
}
.gd-grid-post .gd-post-title a:hover {
    color: var(--gd-primary);
}
.gd-grid-post .gd-post-excerpt {
    font-size: 0.95rem;
    margin-bottom: 1rem;
    flex-grow: 1;
}
.gd-grid-post .gd-post-meta {
    margin-bottom: 0.8rem;
    font-size: 0.88rem;
}
.gd-grid-post .gd-read-more {
    margin-top: auto;
    font-size: 0.95rem;
}

/* Placeholder */
.gd-placeholder-img {
    background: linear-gradient(135deg, #e0f2fe, #bae6fd);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gd-primary);
    font-weight: 600;
    font-size: 1rem;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
    .gd-single-article {
        padding: 2rem;
    }
    .gd-single-title {
        font-size: 2.1rem;
    }
    .gd-archive-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .gd-single-title {
        font-size: 1.9rem;
    }
    .gd-archive-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .gd-single-wrapper, .gd-related-section {
        padding: 2rem 0;
    }
    .gd-single-article {
        padding: 1.5rem;
    }
    .gd-single-title {
        font-size: 1.7rem;
    }
}