/*
Theme Name: Space Company Theme
Theme URI: http://example.com/space-company
Author: Metalxiaoxiao
Author URI: http://example.com
Description: A modern, professional aerospace company theme with sharp angles and blue/white color scheme.
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: space-company
*/

:root {
    --primary: #5AA0FF;
    --primary-strong: #1E3A6D;
    --primary-accent: #2E7BFF;
    --surface: #FFFFFF;
    --surface-muted: #F4F8FF;
    --border: #E6ECF4;
    --text: #0E1B2E;
    --text-muted: #4A5C75;
    --on-primary: #FFFFFF;
}

body.brand-skin-corporate {
    --primary: #3D7BE0;
    --primary-strong: #18305B;
    --primary-accent: #2563EB;
    --surface: #FFFFFF;
    --surface-muted: #F5F8FE;
    --border: #DDE6F5;
    --text: #0C1930;
    --text-muted: #42536E;
    --on-primary: #FFFFFF;
}

body.brand-skin-teal {
    --primary: #2B8FB9;
    --primary-strong: #0F3F54;
    --primary-accent: #1AA3D9;
    --surface: #FFFFFF;
    --surface-muted: #F2FAFD;
    --border: #D9EAF1;
    --text: #0E2330;
    --text-muted: #486170;
    --on-primary: #FFFFFF;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Microsoft YaHei", sans-serif;
    background-color: var(--surface-muted);
    color: var(--text);
    line-height: 1.6;
    background-image:
        linear-gradient(135deg, rgba(255, 255, 255, 0.6) 0%, rgba(244, 248, 255, 0.6) 100%);
}

a {
    color: var(--primary-strong);
    text-decoration: none;
}

/* Header */
.site-header {
    background-color: var(--surface);
    color: var(--text);
    padding: 20px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 5px solid var(--primary-strong);
    position: relative;
    transform: translateY(0);
    transition: background-color 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease, transform 0.35s ease;
}

body.home .site-header,
body.blog .site-header,
body.has-hero-carousel .site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    border-bottom-color: transparent;
    z-index: 50;
}

body.home .site-header::after,
body.blog .site-header::after,
body.has-hero-carousel .site-header::after {
    opacity: 0;
}

body.home .site-main,
body.blog .site-main,
body.has-hero-carousel .site-main {
    padding-top: 0;
    padding-bottom: 0;
}

body.home .site-header.is-merged,
body.blog .site-header.is-merged,
body.has-hero-carousel .site-header.is-merged {
    background: linear-gradient(to bottom, rgba(14, 27, 46, 0.86), rgba(14, 27, 46, 0.36), rgba(14, 27, 46, 0));
    border-bottom-color: transparent;
    backdrop-filter: blur(0);
    box-shadow: none;
}

body.home .site-header.is-merged .site-title a,
body.home .site-header.is-merged .site-description,
body.home .site-header.is-merged .main-navigation a,
body.home .site-header.is-merged .menu-toggle span,
body.blog .site-header.is-merged .site-title a,
body.blog .site-header.is-merged .site-description,
body.blog .site-header.is-merged .main-navigation a,
body.blog .site-header.is-merged .menu-toggle span,
body.has-hero-carousel .site-header.is-merged .site-title a,
body.has-hero-carousel .site-header.is-merged .site-description,
body.has-hero-carousel .site-header.is-merged .main-navigation a,
body.has-hero-carousel .site-header.is-merged .menu-toggle span {
    color: var(--surface);
}

body.home .site-header.is-merged .main-navigation a,
body.blog .site-header.is-merged .main-navigation a,
body.has-hero-carousel .site-header.is-merged .main-navigation a {
    background-color: rgba(255, 255, 255, 0.16);
    border-color: rgba(255, 255, 255, 0.4);
}

body.home .site-header.is-merged::after,
body.blog .site-header.is-merged::after,
body.has-hero-carousel .site-header.is-merged::after {
    opacity: 0;
}

body.home .site-header.is-detached,
body.blog .site-header.is-detached,
body.has-hero-carousel .site-header.is-detached {
    background-color: var(--surface);
    border-bottom-color: var(--primary-strong);
    backdrop-filter: blur(10px);
    box-shadow: 0 6px 14px rgba(14, 27, 46, 0.12);
    animation: headerDetach 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

body.home .site-header.is-detached::after,
body.blog .site-header.is-detached::after,
body.has-hero-carousel .site-header.is-detached::after {
    opacity: 1;
}

body.home .site-header.is-merged .site-logo,
body.blog .site-header.is-merged .site-logo,
body.has-hero-carousel .site-header.is-merged .site-logo {
    opacity: 0;
    visibility: hidden;
    width: 0;
    max-width: 0;
    overflow: hidden;
    transition: opacity 0.25s ease;
}

body.home.show-hero-logo .site-header.is-merged .site-logo,
body.blog.show-hero-logo .site-header.is-merged .site-logo,
body.has-hero-carousel.show-hero-logo .site-header.is-merged .site-logo {
    opacity: 1;
    visibility: visible;
    width: auto;
    max-width: clamp(120px, 18vw, 220px);
}

@keyframes headerDetach {
    from {
        transform: translateY(-12px);
        opacity: 0.9;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.site-branding {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    flex-wrap: nowrap;
}

.site-logo {
    flex: 0 1 auto;
    max-width: clamp(120px, 18vw, 220px);
}

.site-logo .custom-logo-link {
    display: block;
}

.site-logo .custom-logo {
    display: block;
    width: 100%;
    max-height: 46px;
    height: auto;
    object-fit: contain;
}

.site-branding-text {
    min-width: 0;
}

.site-header::after {
    content: '';
    position: absolute;
    bottom: -5px;
    right: 50px;
    width: 100px;
    height: 5px;
    background-color: var(--primary-strong);
    transition: opacity 0.35s ease;
}

.site-title {
    font-size: 32px;
    font-weight: 900;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 5px;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.site-description {
    font-size: 12px;
    letter-spacing: 2px;
    color: var(--text-muted);
    text-transform: uppercase;
}

.main-navigation ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

.main-navigation a {
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    padding: 12px 24px;
    background-color: var(--primary-strong);
    color: var(--surface);
    /* Sharp diagonal cut */
    clip-path: polygon(15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%, 0 15px);
    display: inline-block;
    border: 2px solid transparent;
    transition: background-color 0.35s ease, color 0.35s ease, border-color 0.35s ease;
}

.main-navigation a:hover,
.main-navigation li.current-menu-item>a,
.main-navigation li.current_page_item>a {
    background-color: var(--primary-accent);
}

.menu-toggle {
    display: none;
    background: transparent;
    border: none;
    padding: 0;
    width: 36px;
    height: 30px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    clip-path: none;
}

.menu-toggle span {
    display: block;
    width: 28px;
    height: 3px;
    background-color: var(--primary-strong);
}

/* Main Content */
.site-main {
    padding: 60px 50px;
    max-width: 1400px;
    margin: 0 auto;
}

.news-carousel-section {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    margin-top: 0;
    margin-bottom: 0;
    min-height: 100svh;
}

.news-carousel-card {
    background-color: transparent;
    border: none;
    padding: 0;
    min-height: 100svh;
}

.news-section {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    background-color: #EAF4FF;
    background-image:
        linear-gradient(rgba(46, 123, 255, 0.14) 1px, transparent 1px),
        linear-gradient(90deg, rgba(46, 123, 255, 0.14) 1px, transparent 1px);
    background-size: 32px 32px;
    border-top: none;
    border-bottom: 1px solid var(--border);
    padding: 48px 0;
    margin-bottom: 60px;
}

.news-section-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 50px;
}

.news-carousel {
    position: relative;
    overflow: hidden;
    border: none;
    background-color: #0e1b2e;
    margin-bottom: 0;
    min-height: 100svh;
}

.news-carousel-track {
    display: flex;
    transition: transform 0.35s ease;
}

.news-carousel-slide {
    min-width: 100%;
}

.news-carousel-link {
    display: block;
    position: relative;
}

.news-carousel-image {
    width: 100%;
    height: 100svh;
    object-fit: cover;
    display: block;
}

.news-carousel-image-placeholder {
    background:
        linear-gradient(135deg, #16355f 0%, #0f2645 55%, #091728 100%);
    min-height: 100svh;
}

.news-carousel-caption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 22px 28px 88px;
    background: linear-gradient(to top, rgba(14, 27, 46, 0.9), rgba(14, 27, 46, 0));
}

.news-carousel-caption h3 {
    color: var(--surface);
    font-size: clamp(18px, 2.2vw, 26px);
    line-height: 1.3;
}

.news-carousel-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(14, 27, 46, 0.75);
    color: var(--surface);
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
}

.news-carousel-control.prev {
    left: 10px;
}

.news-carousel-control.next {
    right: 10px;
}

.news-carousel-dots {
    position: absolute;
    left: 50%;
    bottom: 34px;
    transform: translateX(-50%);
    display: flex;
    gap: 0;
    align-items: center;
    z-index: 6;
}

.news-carousel-dot-wrap {
    display: inline-flex;
    align-items: center;
}

.news-carousel-dot {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.95);
    background: rgba(255, 255, 255, 0.38);
    cursor: pointer;
    padding: 0;
    position: relative;
    z-index: 3;
}

.news-carousel-dot.is-active {
    background: var(--surface);
}

.news-carousel-connector {
    width: 52px;
    height: 4px;
    margin: 0 8px;
    background: rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    overflow: hidden;
    position: relative;
}

.news-carousel-connector.is-active {
    background: rgba(255, 255, 255, 0.42);
}

.news-carousel-connector::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: calc(var(--progress, 0) * 100%);
    background: rgba(255, 255, 255, 0.98);
    transition: width 0.05s linear;
}

.page-title-container {
    margin-bottom: 44px;
    display: flex;
    align-items: flex-end;
    border-bottom: 2px solid var(--primary-strong);
    padding-bottom: 16px;
}

.page-title {
    font-size: clamp(24px, 3.2vw, 30px);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 2px;
    line-height: 1;
    margin-bottom: 6px;
}

.page-title-decorator {
    margin-left: 20px;
    width: 50px;
    height: 20px;
    background-color: var(--primary-strong);
    clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}

/* Cards */
.card {
    background-color: var(--surface);
    color: var(--text);
    padding: 2px;
    /* Border thickness */
    margin-bottom: 40px;
    /* Sharp angles */
    clip-path: polygon(30px 0, 100% 0, 100% calc(100% - 30px), calc(100% - 30px) 100%, 0 100%, 0 30px);
    position: relative;
}

.card-inner {
    background-color: var(--surface);
    padding: 30px;
    height: 100%;
    background-image: none;
    clip-path: polygon(29px 0, 100% 0, 100% calc(100% - 29px), calc(100% - 29px) 100%, 0 100%, 0 29px);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--text);
    padding-bottom: 15px;
}

.card-title {
    font-size: 24px;
    font-weight: 900;
    color: var(--primary-strong);
    text-transform: uppercase;
}

.card-meta {
    font-size: 12px;
    font-weight: bold;
    background-color: var(--primary-strong);
    color: var(--surface);
    padding: 4px 10px;
    clip-path: polygon(5px 0, 100% 0, calc(100% - 5px) 100%, 0 100%);
}

.card-content {
    font-size: 15px;
    background-color: var(--surface);
    padding: 20px;
    border: 1px solid var(--border);
    margin-bottom: 20px;
}

.post-grid .card {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: var(--reveal-delay, 0s);
}

.post-grid .card .card-header,
.post-grid .card .post-thumbnail,
.post-grid .card .card-content,
.post-grid .card .btn {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.42s ease, transform 0.42s ease;
}

.post-grid .card.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

.post-grid .card.is-revealed .card-header {
    opacity: 1;
    transform: translateY(0);
    transition-delay: calc(var(--reveal-delay, 0s) + 0.06s);
}

.post-grid .card.is-revealed .post-thumbnail {
    opacity: 1;
    transform: translateY(0);
    transition-delay: calc(var(--reveal-delay, 0s) + 0.12s);
}

.post-grid .card.is-revealed .card-content {
    opacity: 1;
    transform: translateY(0);
    transition-delay: calc(var(--reveal-delay, 0s) + 0.16s);
}

.post-grid .card.is-revealed .btn {
    opacity: 1;
    transform: translateY(0);
    transition-delay: calc(var(--reveal-delay, 0s) + 0.22s);
}

/* Buttons */
.btn {
    display: inline-block;
    background-color: var(--primary-strong);
    color: var(--surface);
    padding: 12px 30px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    clip-path: polygon(15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%, 0 15px);
    border: none;
    cursor: pointer;
}

/* Grid Layout for Posts */
.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 40px;
}

/* Category Blocks (Homepage) */
.category-blocks-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.company-intro-section,
.product-intro-section {
    background-color: var(--surface);
    border: 1px solid var(--border);
    padding: 36px;
    margin-bottom: 60px;
}

.company-intro-section {
    padding: 2px;
}

.company-intro-card-inner {
    padding: 30px;
    background-image: none;
}

.product-intro-section {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    background-color: var(--surface);
    border: none;
    padding: 48px 0 28px;
    margin-bottom: 0;
}

.product-intro-inner {
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 50px;
    padding-right: 50px;
}

.product-intro-inner .page-title-container {
    margin-bottom: 30px;
}

.product-vertical-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 56px;
}

.product-vertical-item {
    display: grid;
    grid-template-columns: minmax(160px, 220px) minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    background-color: var(--surface);
    border: none;
    padding: 18px;
    clip-path: polygon(20px 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 20px);
    background-image: none;
    opacity: 0;
    transform: translateY(22px);
    transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: var(--reveal-delay, 0s);
}

.product-vertical-item.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

.product-vertical-image-wrap {
    width: 100%;
}

.product-vertical-image {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    display: block;
    border: 2px solid var(--primary-strong);
}

.product-vertical-placeholder {
    background: linear-gradient(135deg, #d9e8ff 0%, #eef4ff 100%);
}

.product-vertical-content h3 {
    color: var(--primary-strong);
    font-size: 21px;
    margin-bottom: 8px;
}

.product-vertical-content p {
    color: var(--text-muted);
    line-height: 1.75;
}

body.home .site-footer,
body.blog .site-footer,
body.has-hero-carousel .site-footer {
    margin-top: 0;
}

.company-intro-content {
    color: var(--text);
    font-size: 16px;
    line-height: 1.9;
}

.company-intro-layout {
    display: grid;
    grid-template-columns: minmax(200px, 260px) minmax(0, 1fr);
    gap: 30px;
    align-items: start;
}

.company-intro-side-image-wrap {
    width: 100%;
}

.company-intro-side-image {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    display: block;
    border: 2px solid var(--primary-strong);
    clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px);
}

.company-intro-side-placeholder {
    background: linear-gradient(135deg, #d9e8ff 0%, #eef4ff 100%);
}

.company-intro-main {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.company-intro-content p {
    margin-bottom: 24px;
}

.company-intro-content {
    background-color: var(--surface);
    border: 1px solid var(--border);
    padding: 20px;
    grid-column: 1 / -1;
}

.company-intro-carousel {
    position: relative;
    overflow: hidden;
    border: 2px solid var(--primary-strong);
    background-color: var(--surface);
    clip-path: polygon(18px 0, 100% 0, 100% calc(100% - 18px), calc(100% - 18px) 100%, 0 100%, 0 18px);
}

.company-intro-carousel-track {
    display: flex;
    transition: transform 0.35s ease;
}

.company-intro-carousel-slide {
    min-width: 100%;
}

.company-intro-carousel-image {
    width: 100%;
    height: clamp(220px, 28vw, 320px);
    object-fit: cover;
    display: block;
}

.company-intro-carousel-placeholder {
    background: linear-gradient(135deg, #d9e8ff 0%, #eef4ff 100%);
}

.company-intro-carousel-dots {
    position: absolute;
    left: 50%;
    bottom: 12px;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 2;
}

.company-intro-carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.95);
    padding: 0;
    background-color: rgba(255, 255, 255, 0.42);
    cursor: pointer;
}

.company-intro-carousel-dot.is-active {
    background-color: var(--surface);
}

.product-showcase {
    display: flex;
    flex-direction: column;
    gap: 26px;
}

.product-stage {
    position: relative;
    min-height: clamp(260px, 38vw, 430px);
    overflow: hidden;
}

.product-stage::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: min(42vw, 420px);
    height: min(42vw, 420px);
    transform: translate(-50%, -50%) rotate(45deg);
    background: linear-gradient(135deg, rgba(46, 123, 255, 0.16), rgba(14, 27, 46, 0.08));
    border: 1px solid rgba(30, 58, 109, 0.28);
    z-index: 1;
}

.product-track {
    position: relative;
    height: 100%;
}

.product-slide {
    position: absolute;
    top: 0;
    left: 50%;
    width: 58%;
    height: 100%;
    transform: translateX(-50%) scale(0.88);
    opacity: 0;
    transition: transform 0.45s ease, opacity 0.45s ease, box-shadow 0.45s ease;
    border: none;
    background-color: var(--surface);
    overflow: hidden;
    cursor: pointer;
}

.product-slide.is-active {
    transform: translateX(-50%) scale(1);
    opacity: 1;
    z-index: 4;
    box-shadow: 0 18px 36px rgba(14, 27, 46, 0.25);
}

.product-slide.is-prev,
.product-slide.is-next {
    opacity: 0.9;
    z-index: 3;
}

.product-slide.is-prev {
    left: 20%;
    transform: translateX(-50%) scale(0.78);
}

.product-slide.is-next {
    left: 80%;
    transform: translateX(-50%) scale(0.78);
}

.product-slide.is-hidden {
    opacity: 0;
    pointer-events: none;
    z-index: 1;
}

.product-slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.product-slide-placeholder {
    background: linear-gradient(135deg, #d9e8ff 0%, #eef4ff 100%);
}

.product-slide-title {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 14px 18px;
    color: var(--surface);
    font-size: 20px;
    font-weight: 900;
    background: linear-gradient(to top, rgba(14, 27, 46, 0.88), rgba(14, 27, 46, 0));
}

.product-switch {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 58px;
    height: 58px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--primary-strong);
    font-size: 0;
    font-weight: 400;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 6;
    clip-path: none;
    box-shadow: none;
    text-shadow: 0 0 10px rgba(46, 123, 255, 0.45);
    -webkit-tap-highlight-color: transparent;
    transition: transform 0.2s ease, color 0.2s ease, text-shadow 0.2s ease;
}

.product-switch.prev {
    left: 18%;
}

.product-switch.next {
    right: 18%;
}

.product-switch:hover {
    color: var(--primary-accent);
    transform: translateY(-50%) scale(1.1);
    text-shadow: 0 0 16px rgba(46, 123, 255, 0.65);
}

.product-switch:focus,
.product-switch:active,
.product-switch:focus-visible {
    outline: none;
    background: transparent;
    box-shadow: none;
}

.product-switch::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 32px;
    height: 2px;
    background: linear-gradient(to right, rgba(30, 58, 109, 0), rgba(46, 123, 255, 0.7));
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.product-switch::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 12px;
    height: 12px;
    border-top: 2px solid currentColor;
    border-right: 2px solid currentColor;
    transform: translateY(-50%);
    pointer-events: none;
}

.product-switch.prev::before {
    background: linear-gradient(to left, rgba(30, 58, 109, 0), rgba(46, 123, 255, 0.7));
}

.product-switch.next::before {
    background: linear-gradient(to right, rgba(30, 58, 109, 0), rgba(46, 123, 255, 0.7));
}

.product-switch.prev::after {
    left: 10px;
    transform: translateY(-50%) rotate(-135deg);
}

.product-switch.next::after {
    right: 10px;
    transform: translateY(-50%) rotate(45deg);
}

.product-detail-list {
    min-height: 120px;
}

.product-detail-item {
    display: none;
    border: none;
    background-color: transparent;
    padding: 12px 0 0;
    text-align: center;
}

.product-detail-item.is-active {
    display: block;
}

.product-detail-item h3 {
    color: var(--primary-strong);
    font-size: 22px;
    margin-bottom: 10px;
    text-align: center;
}

.product-detail-item p {
    color: var(--text-muted);
    line-height: 1.75;
    max-width: 760px;
    margin: 0 auto;
    text-align: center;
}

.category-block {
    background-color: var(--surface);
    padding: 30px;
    border: 2px solid var(--primary-strong);
    position: relative;
    /* Square block structure, no clip-path */
}

.category-block-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--primary-strong);
    /* Thick horizontal line under title */
    position: relative;
}

.category-block-header::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 30%;
    height: 3px;
    background-color: var(--primary-accent);
    /* Accent color on the line */
}

.category-block-title {
    font-size: 24px;
    font-weight: 900;
    color: var(--primary-strong);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0;
    line-height: 1;
}

.category-block-more {
    font-size: 12px;
    font-weight: bold;
    color: var(--primary-accent);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.category-post-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.category-post-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px dashed var(--border);
}

.category-post-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.no-posts-message {
    color: var(--text);
    font-style: italic;
    padding: 20px 0;
}

/* Calendar Date Square */
.post-date-calendar {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    background-color: var(--primary-strong);
    color: var(--surface);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    border: 2px solid var(--primary-strong);
    /* Square shape, no rounded corners */
}

.post-date-calendar .date-month {
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    background-color: var(--surface);
    color: var(--primary-strong);
    width: 100%;
    padding: 2px 0;
    border-bottom: 1px solid var(--primary-strong);
}

.post-date-calendar .date-day {
    font-size: 24px;
    font-weight: 900;
    line-height: 1;
    padding-top: 5px;
}

.post-info {
    flex-grow: 1;
}

.post-info .post-title {
    font-size: 16px;
    font-weight: bold;
    margin: 0 0 8px 0;
    line-height: 1.4;
}

.post-info .post-title a {
    color: var(--text);
    transition: color 0.2s;
}

.post-info .post-title a:hover {
    color: var(--primary-accent);
}

.post-info .post-excerpt {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}

/* Footer */
.site-footer {
    background-color: var(--primary-strong);
    color: var(--surface);
    padding: 40px 50px;
    border-top: 5px solid var(--primary-strong);
    margin-top: 80px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.footer-logo-image {
    max-width: 140px;
}

.footer-logo-image .custom-logo-link {
    display: block;
}

.footer-logo-image .custom-logo {
    display: block;
    width: 100%;
    max-height: 34px;
    height: auto;
    object-fit: contain;
}

.footer-logo-text {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.footer-info {
    text-align: right;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
}

.footer-info p {
    margin-bottom: 6px;
}

.footer-info p:last-child {
    margin-bottom: 0;
}

.footer-info a {
    color: var(--surface);
    text-decoration: underline;
}

.footer-info a:hover {
    color: rgba(255, 255, 255, 0.8);
}

/* Single Post & Page */
.single-post-container {
    max-width: 1000px;
    margin: 0 auto;
}

.single-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 40px;
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
}

.meta-item {
    background-color: var(--primary-strong);
    color: var(--surface);
    padding: 6px 15px;
    clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}

.meta-item a {
    color: var(--primary-accent);
}

.single-content-wrapper {
    background-color: var(--surface);
    padding: 2px;
}

.single-content-inner {
    background-color: var(--surface);
    padding: 50px;
    background-image: repeating-linear-gradient(-45deg,
            #ffffff,
            #ffffff 10px,
            #f5f5f5 10px,
            #f5f5f5 20px);
}

.single-thumbnail {
    margin-bottom: 40px;
    border: 3px solid var(--primary-strong);
}

.single-thumbnail img {
    width: 100%;
    height: auto;
    display: block;
}

.single-content {
    background-color: var(--surface);
    padding: 40px;
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 16px;
    line-height: 1.8;
}

.single-content h1,
.single-content h2,
.single-content h3,
.single-content h4 {
    color: var(--primary-strong);
    margin-top: 30px;
    margin-bottom: 15px;
    text-transform: uppercase;
}

.single-content p {
    margin-bottom: 20px;
}

.single-content img {
    max-width: 100%;
    height: auto;
    border: 2px solid var(--primary-strong);
    margin: 20px 0;
}

/* Forms & Inputs */
input[type="text"],
input[type="email"],
input[type="url"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
textarea {
    background-color: var(--surface);
    border: 2px solid var(--primary-strong);
    color: var(--text);
    padding: 12px 15px;
    font-family: inherit;
    font-size: 14px;
    border-radius: 0;
    outline: none;
    width: 100%;
    max-width: 100%;
    display: block;
    margin-bottom: 20px;
}

input:focus,
textarea:focus {
    border-color: var(--primary-accent);
    background-color: var(--surface-muted);
}

button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
    background-color: var(--primary-strong);
    color: var(--surface);
    border: none;
    padding: 12px 30px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    clip-path: polygon(15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%, 0 15px);
    cursor: pointer;
    border-radius: 0;
    display: inline-block;
}

button:active,
input[type="submit"]:active {
    background-color: var(--primary-accent);
}

/* Content Elements */
.single-content blockquote {
    border-left: 5px solid var(--primary-accent);
    background-color: var(--surface-muted);
    padding: 20px;
    margin: 20px 0;
    font-style: italic;
    color: var(--primary-strong);
}

.single-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    border: 2px solid var(--primary-strong);
}

.single-content th,
.single-content td {
    border: 1px solid var(--primary-strong);
    padding: 12px;
    text-align: left;
}

.single-content th {
    background-color: var(--primary-strong);
    color: var(--surface);
    text-transform: uppercase;
}

.single-content tr:nth-child(even) {
    background-color: var(--surface-muted);
}

.single-content ul,
.single-content ol {
    margin: 0 0 20px 20px;
    padding-left: 20px;
}

.single-content li {
    margin-bottom: 10px;
}

.single-content ul {
    list-style-type: square;
}

/* Pagination */
.pagination {
    display: flex;
    gap: 10px;
    margin-top: 40px;
    justify-content: center;
    flex-wrap: wrap;
}

.pagination .nav-links {
    display: flex;
    gap: 10px;
}

.pagination .page-numbers {
    display: inline-block;
    padding: 10px 20px;
    background-color: var(--surface);
    color: var(--primary-strong);
    font-weight: 900;
    border: 2px solid var(--primary-strong);
    clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}

.pagination .page-numbers.current {
    background-color: var(--primary-strong);
    color: var(--surface);
}

/* Comments */
.comments-area {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 5px solid var(--primary-strong);
}

.comments-title {
    font-size: 24px;
    font-weight: 900;
    color: var(--primary-strong);
    text-transform: uppercase;
    margin-bottom: 30px;
}

.comment-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.comment-body {
    background-color: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    padding: 20px;
    margin-bottom: 20px;
    clip-path: polygon(20px 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 20px);
    background-image: repeating-linear-gradient(-45deg,
            #ffffff,
            #ffffff 10px,
            #f5f5f5 10px,
            #f5f5f5 20px);
}

.comment-body a {
    color: var(--primary-accent);
}

.comment-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 10px;
}

.comment-author {
    font-weight: bold;
    color: var(--primary-strong);
    display: flex;
    align-items: center;
    gap: 15px;
    /* Increased gap between avatar and name/time */
}

.comment-author a {
    color: var(--primary-strong);
}

.comment-author img {
    border: 2px solid var(--primary-strong);
    clip-path: polygon(5px 0, 100% 0, calc(100% - 5px) 100%, 0 100%);
}

.comment-metadata {
    font-size: 12px;
    color: var(--primary-strong);
    margin-left: 10px;
}

.comment-content {
    margin-bottom: 20px;
    /* Added space before the reply button */
}

.comment-reply-link {
    display: inline-block;
    background-color: var(--primary-strong);
    color: var(--surface) !important;
    padding: 5px 15px;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
    margin-top: 15px;
    /* Added top margin to separate from content */
}

.comment-reply-link:active {
    background-color: var(--primary-accent);
}

.comment-respond {
    margin-top: 40px;
    background-color: var(--surface);
    color: var(--text);
    padding: 30px;
    border: 2px solid var(--primary-strong);
    clip-path: polygon(30px 0, 100% 0, 100% calc(100% - 30px), calc(100% - 30px) 100%, 0 100%, 0 30px);
    background-image: repeating-linear-gradient(-45deg,
            #ffffff,
            #ffffff 10px,
            #f5f5f5 10px,
            #f5f5f5 20px);
}

.comment-respond a {
    color: var(--primary-accent);
}

.comment-reply-title {
    font-size: 20px;
    font-weight: 900;
    color: var(--primary-strong);
    text-transform: uppercase;
    margin-bottom: 20px;
    display: block;
}

@media (max-width: 900px) {
    .site-header {
        padding: 20px;
        flex-wrap: wrap;
        gap: 16px;
    }

    .site-title {
        font-size: clamp(20px, 5vw, 28px);
        letter-spacing: 2px;
        line-height: 1.1;
    }

    .main-navigation {
        width: 100%;
        display: none;
    }

    .main-navigation.is-open {
        display: block;
    }

    .main-navigation ul {
        flex-direction: column;
        gap: 10px;
        width: 100%;
    }

    .main-navigation a {
        display: block;
        width: 100%;
        text-align: center;
        padding: 10px 14px;
    }

    .menu-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .site-header::after {
        right: 20px;
    }

    .site-logo {
        max-width: clamp(100px, 36vw, 180px);
    }

    .site-logo .custom-logo {
        max-height: 38px;
    }

    .news-carousel-section {
        min-height: 100svh;
    }

    .news-carousel,
    .news-carousel-card,
    .news-carousel-image,
    .news-carousel-image-placeholder {
        min-height: 100svh;
        height: 100svh;
    }

    .news-carousel-caption {
        padding: 18px 16px 78px;
    }

    .news-section {
        padding: 32px 0;
    }

    .news-section-inner {
        padding: 0 20px;
    }

    .company-intro-section,
    .product-intro-section {
        padding: 24px;
    }

    .company-intro-section {
        padding: 2px;
        opacity: 0;
        transform: translateY(26px) scale(0.985);
        transition: opacity 0.62s ease, transform 0.62s cubic-bezier(0.22, 1, 0.36, 1);
    }

    .company-intro-section.is-revealed {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

    .company-intro-card-inner {
        padding: 22px;
    }

    .company-intro-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .company-intro-side-image {
        max-width: 280px;
    }

    .company-intro-carousel {
        order: 1;
    }

    .company-intro-content {
        order: 2;
        grid-column: auto;
    }

    .company-intro-side-image-wrap {
        order: 3;
    }

    .product-intro-section {
        padding: 32px 0 40px;
    }

    .product-intro-inner {
        padding-left: 20px;
        padding-right: 20px;
    }

    .product-vertical-item {
        grid-template-columns: minmax(130px, 180px) minmax(0, 1fr);
        gap: 14px;
        padding: 14px;
    }

    .product-slide {
        width: 72%;
    }

    .product-slide.is-prev {
        left: 14%;
    }

    .product-slide.is-next {
        left: 86%;
    }

    .product-switch.prev {
        left: 11%;
    }

    .product-switch.next {
        right: 11%;
    }
}

@media (max-width: 480px) {
    .site-title {
        font-size: clamp(16px, 7vw, 22px);
        letter-spacing: 1px;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .site-description {
        font-size: 10px;
        letter-spacing: 1px;
    }

    .product-stage {
        min-height: 230px;
    }

    .product-intro-inner {
        padding-left: 16px;
        padding-right: 16px;
    }

    .product-vertical-item {
        grid-template-columns: 1fr;
    }

    .company-intro-side-image {
        max-width: 100%;
    }

    .company-intro-card-inner {
        padding: 18px;
    }

    .product-slide {
        width: 84%;
    }

    .product-slide.is-prev {
        left: 8%;
    }

    .product-slide.is-next {
        left: 92%;
    }

    .product-switch {
        width: 46px;
        height: 46px;
        font-size: 0;
    }

    .product-switch.prev {
        left: 4%;
    }

    .product-switch.next {
        right: 4%;
    }
}

@media (prefers-reduced-motion: reduce) {

    .company-intro-section,
    .product-vertical-item,
    .post-grid .card,
    .post-grid .card .card-header,
    .post-grid .card .post-thumbnail,
    .post-grid .card .card-content,
    .post-grid .card .btn {
        opacity: 1;
        transform: none;
        transition: none;
    }
}
