/* DogCalorieTool.org - Global Styles */
/* CSS Prefix: dct- */
/* Primary: #E07B39 (Orange) | Secondary: #2D5A4A (Forest) | Accent: #F5A623 (Gold) */
/* Background: #FFFBF7 | Text: #2C2C2C */

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: #2C2C2C;
    background: #FFFBF7;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}
a { color: #E07B39; text-decoration: none; transition: color 0.2s; }
a:hover { color: #c46a2f; text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

/* ===== LAYOUT ===== */
.dct-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}
.dct-section {
    padding: 60px 0;
}
.dct-grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}
.dct-grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}
.dct-flex {
    display: flex;
    align-items: center;
    gap: 15px;
}
.dct-flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ===== HEADER ===== */
.dct-header {
    background: #fff;
    border-bottom: 1px solid #f0e6dc;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}
.dct-header-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.dct-logo {
    font-size: 1.4rem;
    font-weight: 800;
    color: #E07B39;
    display: flex;
    align-items: center;
    gap: 8px;
}
.dct-logo svg {
    width: 32px;
    height: 32px;
}
.dct-nav {
    display: flex;
    gap: 28px;
    align-items: center;
}
.dct-nav a {
    color: #555;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 6px 0;
    position: relative;
}
.dct-nav a:hover {
    color: #E07B39;
    text-decoration: none;
}
.dct-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: #E07B39;
    transition: width 0.3s;
}
.dct-nav a:hover::after { width: 100%; }
.dct-nav a.active { color: #E07B39; }
.dct-nav a.active::after { width: 100%; }

/* Mobile menu */
.dct-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}
.dct-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: #2C2C2C;
    margin: 5px 0;
    transition: 0.3s;
}

/* ===== HERO ===== */
.dct-hero {
    background: linear-gradient(135deg, #E07B39 0%, #f0a06e 100%);
    color: #fff;
    padding: 80px 0 60px;
    text-align: center;
}
.dct-hero h1 {
    font-size: 2.6rem;
    font-weight: 800;
    margin-bottom: 16px;
    line-height: 1.2;
}
.dct-hero p {
    font-size: 1.15rem;
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto 30px;
}
.dct-hero-cta {
    display: inline-flex;
    gap: 15px;
    margin-top: 10px;
}
.dct-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}
.dct-btn-primary {
    background: #fff;
    color: #E07B39;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.dct-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
    text-decoration: none;
    color: #c46a2f;
}
.dct-btn-secondary {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(255,255,255,0.5);
}
.dct-btn-secondary:hover {
    background: rgba(255,255,255,0.15);
    text-decoration: none;
    color: #fff;
}

/* ===== TOOL CARDS (Homepage) ===== */
.dct-tools-section {
    padding: 60px 0;
    background: #fff;
}
.dct-section-title {
    text-align: center;
    margin-bottom: 40px;
}
.dct-section-title h2 {
    font-size: 1.9rem;
    color: #2C2C2C;
    margin-bottom: 10px;
}
.dct-section-title p {
    color: #777;
    font-size: 1.05rem;
}
.dct-tool-card {
    background: #fff;
    border: 1px solid #f0e6dc;
    border-radius: 16px;
    padding: 32px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}
.dct-tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #E07B39, #F5A623);
    opacity: 0;
    transition: opacity 0.3s;
}
.dct-tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px rgba(224,123,57,0.12);
    border-color: #E07B39;
}
.dct-tool-card:hover::before { opacity: 1; }
.dct-tool-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #E07B39, #F5A623);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    color: #fff;
    font-size: 1.5rem;
}
.dct-tool-card h3 {
    font-size: 1.25rem;
    margin-bottom: 10px;
    color: #2C2C2C;
}
.dct-tool-card p {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 20px;
    line-height: 1.6;
}
.dct-tool-card .dct-btn {
    padding: 10px 20px;
    font-size: 0.9rem;
}

/* ===== TOOL PAGES ===== */
.dct-tool-page {
    padding: 40px 0 60px;
}
.dct-tool-header {
    text-align: center;
    margin-bottom: 40px;
}
.dct-tool-header h1 {
    font-size: 2rem;
    margin-bottom: 10px;
}
.dct-tool-header p {
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}
.dct-tool-box {
    background: #fff;
    border: 1px solid #f0e6dc;
    border-radius: 16px;
    padding: 40px;
    max-width: 700px;
    margin: 0 auto 40px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.04);
}
.dct-form-group {
    margin-bottom: 24px;
}
.dct-form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
    font-size: 0.95rem;
}
.dct-form-group input,
.dct-form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #eee;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.2s;
    background: #fff;
    color: #2C2C2C;
}
.dct-form-group input:focus,
.dct-form-group select:focus {
    outline: none;
    border-color: #E07B39;
}
.dct-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.dct-calculate-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #E07B39, #d4692a);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 10px;
}
.dct-calculate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(224,123,57,0.3);
}
.dct-results {
    background: linear-gradient(135deg, #fff8f0, #fff);
    border: 2px solid #E07B39;
    border-radius: 12px;
    padding: 28px;
    margin-top: 24px;
    display: none;
}
.dct-results.show { display: block; animation: dctFadeIn 0.4s; }
@keyframes dctFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
.dct-result-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: #E07B39;
    text-align: center;
    margin: 10px 0;
}
.dct-result-label {
    text-align: center;
    color: #777;
    font-size: 0.95rem;
    margin-bottom: 20px;
}
.dct-result-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 20px;
}
.dct-result-item {
    text-align: center;
    padding: 16px;
    background: #fff;
    border-radius: 10px;
    border: 1px solid #f0e6dc;
}
.dct-result-item .value {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2D5A4A;
}
.dct-result-item .label {
    font-size: 0.8rem;
    color: #888;
    margin-top: 4px;
}

/* Sticky features */
.dct-sticky-bar {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 20px;
    flex-wrap: wrap;
}
.dct-sticky-btn {
    padding: 8px 16px;
    border: 1px solid #ddd;
    border-radius: 20px;
    background: #fff;
    color: #555;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}
.dct-sticky-btn:hover {
    border-color: #E07B39;
    color: #E07B39;
}
.dct-history-list {
    margin-top: 20px;
    max-height: 200px;
    overflow-y: auto;
}
.dct-history-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 14px;
    border-bottom: 1px solid #f0e6dc;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.2s;
}
.dct-history-item:hover {
    background: #fff8f0;
}
.dct-history-item .name { font-weight: 500; }
.dct-history-item .cal { color: #E07B39; font-weight: 600; }

/* ===== BLOG ===== */
.dct-blog-hero {
    background: linear-gradient(135deg, #2D5A4A 0%, #3d7a64 100%);
    color: #fff;
    padding: 60px 0 50px;
    text-align: center;
}
.dct-blog-hero h1 { font-size: 2.2rem; margin-bottom: 10px; }
.dct-blog-hero p { opacity: 0.9; }
.dct-blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
    padding: 40px 0;
}
.dct-blog-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #f0e6dc;
    transition: all 0.3s;
}
.dct-blog-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}
.dct-blog-card-img {
    height: 180px;
    background: linear-gradient(135deg, #E07B39, #F5A623);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 3rem;
}
.dct-blog-card-body {
    padding: 24px;
}
.dct-blog-card-body .dct-meta {
    display: flex;
    gap: 12px;
    font-size: 0.8rem;
    color: #999;
    margin-bottom: 10px;
}
.dct-blog-card-body h3 {
    font-size: 1.15rem;
    margin-bottom: 10px;
    line-height: 1.4;
    color: #2C2C2C;
}
.dct-blog-card-body p {
    color: #666;
    font-size: 0.92rem;
    line-height: 1.6;
    margin-bottom: 15px;
}
.dct-read-more {
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* Article page */
.dct-article {
    max-width: 720px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}
.dct-article-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #f0e6dc;
}
.dct-article-header h1 {
    font-size: 1.9rem;
    line-height: 1.3;
    margin-bottom: 15px;
}
.dct-article-meta {
    display: flex;
    gap: 15px;
    align-items: center;
    color: #888;
    font-size: 0.9rem;
}
.dct-article-meta .author {
    color: #E07B39;
    font-weight: 600;
}
.dct-article-body {
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333;
}
.dct-article-body h2 {
    font-size: 1.5rem;
    margin: 35px 0 15px;
    color: #2C2C2C;
    padding-bottom: 8px;
    border-bottom: 2px solid #f0e6dc;
}
.dct-article-body h3 {
    font-size: 1.2rem;
    margin: 25px 0 12px;
    color: #444;
}
.dct-article-body p {
    margin-bottom: 18px;
}
.dct-article-body ul, .dct-article-body ol {
    margin: 15px 0 15px 25px;
}
.dct-article-body li {
    margin-bottom: 8px;
}
.dct-article-body strong {
    color: #2C2C2C;
}
.dct-article-body blockquote {
    border-left: 4px solid #E07B39;
    padding: 15px 20px;
    margin: 20px 0;
    background: #fff8f0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: #555;
}

/* Inline tool recommendation */
.dct-inline-tool {
    background: linear-gradient(135deg, #fff8f0, #fff);
    border: 2px solid #E07B39;
    border-radius: 12px;
    padding: 24px;
    margin: 30px 0;
    text-align: center;
}
.dct-inline-tool h4 {
    color: #E07B39;
    margin-bottom: 8px;
}
.dct-inline-tool p {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 15px;
}

/* Related articles */
.dct-related {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 2px solid #f0e6dc;
}
.dct-related h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
}
.dct-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

/* ===== ADS ===== */
.dct-ad-header, .dct-ad-mid, .dct-ad-bottom,
.dct-ad-sidebar, .dct-ad-tool-top, .dct-ad-tool-bottom,
.dct-ad-home-top, .dct-ad-home-mid, .dct-ad-home-bottom {
    border: 2px dashed #e8ddd3;
    border-radius: 12px;
    background: rgba(255,255,255,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}
.dct-ad-header:not(.has-content),
.dct-ad-mid:not(.has-content),
.dct-ad-bottom:not(.has-content),
.dct-ad-sidebar:not(.has-content),
.dct-ad-tool-top:not(.has-content),
.dct-ad-tool-bottom:not(.has-content),
.dct-ad-home-top:not(.has-content),
.dct-ad-home-mid:not(.has-content),
.dct-ad-home-bottom:not(.has-content) {
    display: none;
}
.dct-ad-label {
    position: absolute;
    top: 4px;
    right: 8px;
    font-size: 0.7rem;
    color: #ccc;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===== FOOTER ===== */
.dct-footer {
    background: #2C2C2C;
    color: #aaa;
    padding: 50px 0 30px;
    margin-top: 60px;
}
.dct-footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}
.dct-footer-brand {
    font-size: 1.3rem;
    font-weight: 700;
    color: #E07B39;
    margin-bottom: 12px;
}
.dct-footer p {
    font-size: 0.9rem;
    line-height: 1.7;
    color: #999;
}
.dct-footer h4 {
    color: #fff;
    font-size: 0.95rem;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.dct-footer-links {
    list-style: none;
}
.dct-footer-links li {
    margin-bottom: 10px;
}
.dct-footer-links a {
    color: #999;
    font-size: 0.9rem;
    transition: color 0.2s;
}
.dct-footer-links a:hover {
    color: #E07B39;
    text-decoration: none;
}
.dct-footer-bottom {
    border-top: 1px solid #444;
    padding-top: 20px;
    text-align: center;
    font-size: 0.85rem;
    color: #777;
}

/* ===== STATIC PAGES ===== */
.dct-page-header {
    background: linear-gradient(135deg, #2D5A4A 0%, #3d7a64 100%);
    color: #fff;
    padding: 50px 0 40px;
    text-align: center;
}
.dct-page-header h1 {
    font-size: 2rem;
    margin-bottom: 8px;
}
.dct-page-header p {
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}
.dct-page-content {
    max-width: 720px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}
.dct-page-content h2 {
    font-size: 1.4rem;
    margin: 30px 0 15px;
    color: #2C2C2C;
}
.dct-page-content p {
    margin-bottom: 16px;
    color: #444;
    line-height: 1.7;
}
.dct-page-content ul {
    margin: 15px 0 15px 25px;
}
.dct-page-content li {
    margin-bottom: 8px;
    color: #444;
}
.dct-contact-box {
    background: #fff;
    border: 1px solid #f0e6dc;
    border-radius: 12px;
    padding: 30px;
    margin: 30px 0;
    text-align: center;
}
.dct-contact-box .email {
    font-size: 1.2rem;
    color: #E07B39;
    font-weight: 600;
    margin: 10px 0;
}

/* ===== FAQ ===== */
.dct-faq-item {
    border-bottom: 1px solid #f0e6dc;
    padding: 20px 0;
}
.dct-faq-question {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2C2C2C;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.dct-faq-question::after {
    content: '+';
    font-size: 1.5rem;
    color: #E07B39;
    transition: transform 0.3s;
}
.dct-faq-item.open .dct-faq-question::after {
    transform: rotate(45deg);
}
.dct-faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s;
    color: #555;
    line-height: 1.7;
}
.dct-faq-item.open .dct-faq-answer {
    max-height: 500px;
    padding-top: 12px;
}

/* ===== 404 ===== */
.dct-404 {
    text-align: center;
    padding: 100px 20px;
}
.dct-404 h1 {
    font-size: 6rem;
    color: #E07B39;
    margin-bottom: 10px;
}
.dct-404 p {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 30px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .dct-header-inner { height: 56px; }
    .dct-nav { display: none; }
    .dct-menu-btn { display: block; }
    .dct-hero h1 { font-size: 1.8rem; }
    .dct-hero p { font-size: 1rem; }
    .dct-grid-2, .dct-grid-3 { grid-template-columns: 1fr; }
    .dct-form-row { grid-template-columns: 1fr; }
    .dct-result-grid { grid-template-columns: 1fr; }
    .dct-footer-grid { grid-template-columns: 1fr 1fr; gap: 20px; }
    .dct-article-header h1 { font-size: 1.5rem; }
    .dct-tool-box { padding: 24px; }
}

@media (max-width: 480px) {
    .dct-hero { padding: 50px 0 40px; }
    .dct-section { padding: 40px 0; }
    .dct-footer-grid { grid-template-columns: 1fr; }
    .dct-hero-cta { flex-direction: column; }
}

/* Mobile nav overlay */
.dct-mobile-nav {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 99;
}
.dct-mobile-nav.active { display: block; }
.dct-mobile-menu {
    position: absolute;
    top: 0; right: 0;
    width: 280px;
    height: 100%;
    background: #fff;
    padding: 80px 30px 30px;
    box-shadow: -5px 0 20px rgba(0,0,0,0.1);
}
.dct-mobile-menu a {
    display: block;
    padding: 14px 0;
    font-size: 1.1rem;
    color: #333;
    border-bottom: 1px solid #f0e6dc;
}
.dct-mobile-menu a:hover { color: #E07B39; }
