/*
Theme Name: Yworth
Theme URI: https://yworth.example/
Author: Yworth
Description: 宥纬科技企业展示与内容管理主题。
Version: 1.0.0
Text Domain: yworth
*/

@import url("assets/css/style.css");

.wp-site-blocks { overflow: clip; }
.nav a.active { color: #c3211e; border-bottom-color: #c3211e; }
.product-empty { padding: 32px; color: var(--muted); text-align: center; }
.entry-content > :first-child { margin-top: 0; }
.entry-content > :last-child { margin-bottom: 0; }
.article-content img { max-width: 100%; height: auto; }
.article-content a { color: #c3211e; }
.article-content ul, .article-content ol { margin: 0 0 18px; padding-left: 1.4em; }
.article-content li { margin: 7px 0; }
.wp-admin-bar .header { top: 32px; }
@media (max-width: 782px) { .wp-admin-bar .header { top: 46px; } }

.hero .actions .btn.primary,
.hero .actions .btn.ghost {
    background: transparent;
    border-color: rgba(255, 255, 255, .62);
    color: #fff;
}

.hero .actions .btn.primary:hover,
.hero .actions .btn.ghost:hover {
    background: #c3211e;
    border-color: #c3211e;
    color: #fff;
}

.hero .actions .btn.primary:active,
.hero .actions .btn.ghost:active {
    background: #901310;
    border-color: #901310;
}

#inquiry .form textarea { resize: vertical; }
.inquiry-feedback { margin: 0; color: #2f7d57; font-weight: 700; }
.inquiry-feedback.inquiry-error { color: #c3211e; }

.news-card .body { padding: 16px 18px 18px; }
.news-card h3 { margin: 0; font-size: 17px; line-height: 1.45; }
.news-card h3 a { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.news-card h3 a:hover { color: #c3211e; }
.news-pagination { display: flex; justify-content: center; gap: 8px; margin: 20px auto 0; }
.news-pagination .page-numbers { min-width: 38px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 4px; text-align: center; color: var(--ink); }
.news-pagination .page-numbers.current, .news-pagination .page-numbers:hover { color: #fff; background: #c3211e; border-color: #c3211e; }
@media (max-width: 900px) { .news-card h3 { font-size: 16px; } .news-card h3 a { white-space: normal; } }

.home-value-section { padding: 42px 0 22px; }
.home-value-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.home-value-card { min-height: 164px; padding: 24px 30px; border: 1px solid var(--line); border-radius: 8px; background: #fff; transition: border-color .2s ease, box-shadow .2s ease; }
.home-value-card:hover { border-color: #e8aaa7; box-shadow: 0 10px 26px rgba(20, 33, 61, .08); }
.home-value-heading { display: flex; align-items: center; justify-content: center; gap: 14px; margin-bottom: 14px; text-align: left; }
.home-value-heading img { width: 42px; height: 42px; flex: 0 0 auto; opacity: .48; }
.home-value-heading h2 { margin: 0 0 1px; color: var(--ink); font-size: 25px; line-height: 1.15; }
.home-value-heading span { display: block; color: #c3211e; font-weight: 800; font-size: 13px; line-height: 1.25; }
.home-value-card p { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.75; text-align: center; }
.home-value-grid.home-value-ready .home-value-card { opacity: 0; transform: translateY(22px); transition: opacity .5s ease, transform .5s ease, border-color .2s ease, box-shadow .2s ease; }
.home-value-grid.home-value-ready .home-value-card.is-visible { opacity: 1; transform: translateY(0); }
.home-value-grid.home-value-ready .home-value-card:nth-child(2) { transition-delay: .1s; }
.home-value-grid.home-value-ready .home-value-card:nth-child(3) { transition-delay: .2s; }
@media (prefers-reduced-motion: reduce) { .home-value-grid.home-value-ready .home-value-card { opacity: 1; transform: none; transition: none; } }
.hero-mobile-break { display: none; }
@media (max-width: 900px) { .home-value-section { padding: 32px 0 14px; } .home-value-grid { grid-template-columns: 1fr; gap: 14px; } .home-value-card { min-height: 0; padding: 22px; } .home-value-heading img { width: 36px; height: 36px; } .home-value-heading h2 { font-size: 22px; } }

@media (max-width: 900px) {
    .navwrap { height: 68px; gap: 12px; position: relative; }
    .logo { min-width: 0; }
    .logo img { height: 36px; max-width: calc(100vw - 126px); object-fit: contain; object-position: left center; }
    .header .navwrap > .nav-toggle { display: inline-flex !important; align-items: center; justify-content: center; position: absolute; right: 0; top: 14px; z-index: 60; visibility: visible !important; opacity: 1 !important; padding: 8px 10px; background: #c3211e !important; color: #fff !important; }
    .nav { top: 68px; }
    .hero h1 { max-width: 100%; font-size: 30px; line-height: 1.25; overflow-wrap: anywhere; white-space: normal !important; word-break: break-all; }
    .hero-mobile-break { display: inline; }
    .hero .container { min-height: 500px; }
}

.about-intro .about-copy h2 { margin-top: 0; }
@media (min-width: 901px) {
    .about-intro { align-items: stretch; }
    .about-intro > img {
        align-self: start;
        width: 100%;
        height: calc(100% - 30px);
        min-height: 0;
        margin-top: 10px;
        object-fit: cover;
        object-position: center;
    }
}
