/* Variables & Reset */
:root {
    --primary-color: #0c2646;
    /* Deeper Navy Blue for Premium feel */
    --accent-color: #3b7bbf;
    /* Calmer Sky Blue */
    --gold-accent: #c4a77d;
    /* Gold/Beige Accent */
    --text-color: #333333;
    --light-bg: #f8f9fa;
    /* Lighter, cleaner gray */
    --white: #ffffff;
    --font-main: 'Noto Sans JP', sans-serif;
    --font-serif: 'Noto Serif JP', serif;
    --transition-speed: 0.3s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--white);
}

a {
    text-decoration: none;
    color: inherit;
    transition: opacity var(--transition-speed);
}

ul {
    list-style: none;
}

.container {
    max-width: 1300px;
    /* Widened for better layout */
    margin: 0 auto;
    padding: 0 40px;
    /* Increased padding slightly */
}

/* Utility Classes */
.text-center {
    text-align: center;
}

/* Typography Utilities */
.section-title {
    font-family: var(--font-serif);
    font-size: 2.4rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary-color);
    position: relative;
    padding-bottom: 20px;
    letter-spacing: 0.08em;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background-color: var(--gold-accent);
    /* Changed to gold accent */
}

h1,
h2,
h3 {
    font-family: var(--font-serif);
    letter-spacing: 0.05em;
}



.section-subtitle {
    text-align: center;
    margin-bottom: 50px;
    font-size: 1.1rem;
    color: #666;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 30px;
    border-radius: 4px;
    /* Structured, sharp rectangle */
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
    border: 2px solid var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(12, 38, 70, 0.15);
}

.lg-btn {
    font-size: 1.15rem;
    padding: 18px 45px;
    min-width: 250px;
    letter-spacing: 0.1em;
}

.sm-btn {
    font-size: 0.95rem;
    padding: 10px 20px;
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Header */
.site-header {
    background: var(--primary-color);
    /* Match the logo/footer dark color */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
    /* Increased to fit the larger logo */
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    align-items: center;
}

.header-logo-img {
    height: 60px;
    width: auto;
    display: block;
    filter: invert(1) brightness(1.5);
    mix-blend-mode: screen;
}

.footer-logo-img {
    height: 80px;
    width: auto;
    filter: invert(1) brightness(1.5);
    mix-blend-mode: screen;
}

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

.main-nav a:not(.btn) {
    font-weight: 500;
    color: var(--white);
    /* White text to stand out on dark header */
    position: relative;
}

.main-nav a:not(.btn)::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--gold-accent);
    /* Changed hover underline to gold */
    transition: width var(--transition-speed);
}

.main-nav a:not(.btn):hover::after {
    width: 100%;
}

/* Hero Section (Slider) */
.hero-section {
    position: relative;
    height: 90vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    overflow: hidden;
    /* For slider */
}

.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    /* Parallax effect */
    opacity: 0;
    transition: opacity 1.5s ease-in-out, transform 6s linear;
    /* Subtle zoom effect */
    transform: scale(1);
}

.slide.active {
    opacity: 1;
    transform: scale(1.05);
    /* Zoom in slowly while active */
}

/* Slider Controls */
.slider-controls {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    gap: 15px;
}

.dot {
    width: 12px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color var(--transition-speed);
}

.dot.active,
.dot:hover {
    background-color: var(--white);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1000px;
    /* Widened for better heading display */
    width: 100%;
}

.hero-title {
    font-family: var(--font-serif);
    font-size: 3rem;
    /* Reduced from 3.5rem to fit long Japanese strings */
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 25px;
    letter-spacing: 0.05em;
    /* Reduced from 0.08em */
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.hero-title .highlight {
    color: var(--gold-accent);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 40px;
    opacity: 0.95;
    letter-spacing: 0.05em;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.5);
}

/* Common Section Styles */
.section {
    padding: 120px 0;
    /* Huge wide spacing */
}

/* Problems Section */
.problems-section {
    background-color: var(--white);
}

.problems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.problem-card {
    background: var(--white);
    padding: 40px 30px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: transform var(--transition-speed);
    border: 1px solid #eee;
}

.problem-card:hover {
    transform: translateY(-10px);
}

.problem-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.problem-card h3 {
    font-size: 1.25rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.problem-card p {
    font-size: 0.95rem;
    color: #666;
}

/* Strengths Section */
.strengths-section {
    background-color: var(--light-bg);
}

.strength-highlight {
    background: var(--white);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    margin-bottom: 60px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.strength-graph-container h3 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 1.5rem;
    color: var(--primary-color);
}

.response-rate-comparison {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.rate-bar {
    display: flex;
    align-items: center;
    height: 50px;
}

.rate-label {
    width: 100px;
    font-weight: 700;
}

.bar-fill {
    height: 100%;
    border-radius: 0 25px 25px 0;
    display: flex;
    align-items: center;
    padding-left: 15px;
    color: var(--white);
    font-weight: 700;
    transition: width 1.5s ease-out;
    width: 0;
    /* Animated by JS potentially or just static for now */
}

.company-rate .bar-fill {
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

.market-rate .bar-fill {
    background-color: #bdc3c7;
    color: #333;
}

.strengths-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

.strength-card {
    flex: 1 1 calc(33.333% - 20px);
    /* 3 cards per row maximum */
    min-width: 300px;
    max-width: 380px;
    /* Prevents 2 items on second row from spanning entire width */
    background: var(--white);
    padding: 30px;
    border-radius: 10px;
    position: relative;
    border-top: 4px solid var(--accent-color);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.strength-number {
    font-size: 3rem;
    font-weight: 900;
    color: rgba(10, 46, 92, 0.1);
    position: absolute;
    top: 10px;
    right: 20px;
    line-height: 1;
}

.strength-card h3 {
    font-size: 1.25rem;
    margin-bottom: 15px;
    padding-right: 40px;
    color: var(--primary-color);
}

/* Services Section */
.services-section {
    background-color: var(--white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

/* Staggered (Alternating) Layouts */
.staggered-row {
    display: flex;
    align-items: center;
    gap: 50px;
    margin-bottom: 80px;
}

.staggered-row:last-child {
    margin-bottom: 0;
}

.staggered-row.reverse {
    flex-direction: row-reverse;
}

.staggered-image {
    flex: 1;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.staggered-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    aspect-ratio: 16/9;
}

.staggered-text {
    flex: 1;
}

.staggered-text h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.staggered-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
    margin-bottom: 30px;
}

@media (max-width: 900px) {

    .staggered-row,
    .staggered-row.reverse {
        flex-direction: column;
        gap: 30px;
    }
}

.service-card {
    background: var(--light-bg);
    border-radius: 10px;
    overflow: hidden;
    transition: transform var(--transition-speed);
    text-align: center;
    padding: 30px;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.service-card p {
    color: #666;
}

/* Abstract Service Section (Top Page) */
.abstract-service-box {
    background: var(--light-bg);
    border-radius: 15px;
    padding: 50px;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.abstract-service-content h3 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.abstract-service-content p {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 30px;
}

/* Detailed Services Section (Services Page) */
.detailed-services-section {
    background-color: var(--white);
}

.service-detail-block {
    display: flex;
    align-items: flex-start;
    gap: 40px;
    margin-bottom: 60px;
    padding: 40px;
    background: var(--white);
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    border: 1px solid #f0f0f0;
}

.service-detail-block:last-child {
    margin-bottom: 0;
}

.service-detail-icon {
    font-size: 3rem;
    color: var(--accent-color);
    flex-shrink: 0;
    width: 80px;
    text-align: center;
}

.service-detail-content h2 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.service-detail-content p {
    font-size: 1.1rem;
    color: #555;
    line-height: 1.8;
}

@media (max-width: 768px) {
    .service-detail-block {
        flex-direction: column;
        text-align: center;
        padding: 30px 20px;
        gap: 20px;
    }

    .service-detail-icon {
        width: 100%;
    }
}

/* Case Studies Section (index.html) */
.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
}

.case-card {
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.case-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

/* Pricing Section */
.pricing-section {
    background-color: var(--primary-color);
    color: var(--white);
}

.pricing-section .section-title {
    color: var(--white);
}

.pricing-section .section-subtitle {
    color: rgba(255, 255, 255, 0.8);
}

.pricing-table-container {
    background: var(--white);
    border-radius: 15px;
    overflow: hidden;
    color: var(--text-color);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    margin-top: 40px;
}

.pricing-table {
    width: 100%;
    border-collapse: collapse;
}

.pricing-table th,
.pricing-table td {
    padding: 20px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

.pricing-table th {
    background-color: #f8f9fa;
    font-size: 1.1rem;
    font-weight: 700;
}

.pricing-table th.highlight-col {
    background-color: #e6f7ff;
    color: var(--primary-color);
    border-top: 4px solid var(--accent-color);
}

.pricing-table td.highlight-col {
    background-color: #f0f9ff;
    font-weight: 600;
    color: var(--primary-color);
}

.price-difference {
    color: #e74c3c;
    font-weight: 700;
    font-size: 1.1rem;
}

/* Parallax General Style */
.parallax-section {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    position: relative;
    color: var(--white);
}

.parallax-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 46, 92, 0.85);
    /* Default Navy Overlay */
    z-index: 1;
}

.parallax-section>.container {
    position: relative;
    z-index: 2;
}

/* Parallax General Style */
.parallax-section {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    position: relative;
    color: var(--white);
}

.parallax-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 46, 92, 0.85);
    /* Default Navy Overlay */
    z-index: 1;
}

.parallax-section>.container {
    position: relative;
    z-index: 2;
}

/* Contact/CTA Section (Old simple CTA, kept for subpages) */
.cta-section {
    padding: 100px 0;
    text-align: center;
    background-image: url('assets/cta_bg.png');
}

.cta-content {
    position: relative;
    z-index: 1;
}

.cta-title {
    font-size: 2.5rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.cta-text {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

/* Rich Contact Form Section */
.contact-section {
    background-color: var(--light-bg);
}

.contact-form-container {
    max-width: 700px;
    margin: 0 auto;
    background: var(--white);
    padding: 50px;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 700;
    color: var(--primary-color);
}

.required {
    background-color: #e74c3c;
    color: var(--white);
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 3px;
    margin-left: 10px;
    vertical-align: middle;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color var(--transition-speed);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

/* Custom Checkbox */
.checkbox-group {
    margin: 30px 0;
    text-align: center;
}

.checkbox-container {
    display: inline-block;
    position: relative;
    padding-left: 35px;
    margin-bottom: 12px;
    cursor: pointer;
    font-size: 1rem;
    user-select: none;
    color: var(--text-color);
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 25px;
    width: 25px;
    background-color: #f4f4f4;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: background-color 0.2s, border-color 0.2s;
}

.checkbox-container:hover input~.checkmark {
    background-color: #e9e9e9;
}

.checkbox-container input:checked~.checkmark {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked~.checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 9px;
    top: 5px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

.privacy-link {
    color: var(--accent-color);
    text-decoration: underline;
}

.form-submit {
    margin-top: 30px;
}

/* FAQ Section */
.faq-section {
    background-color: var(--white);
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    margin-bottom: 20px;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
}

.faq-question {
    width: 100%;
    text-align: left;
    background-color: var(--white);
    padding: 20px 30px;
    border: none;
    outline: none;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color var(--transition-speed);
}

.faq-question:hover {
    background-color: #f9fbfd;
}

.faq-question i {
    color: var(--accent-color);
    transition: transform var(--transition-speed);
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    background-color: var(--white);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
}

.faq-answer p {
    padding: 0 30px 25px;
    color: #555;
    line-height: 1.8;
}

/* Floating CTA (Vertical Banner like seiwa-stss.jp) */
.floating-cta {
    position: fixed;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    background-color: var(--primary-color);
    color: var(--white);
    padding: 25px 12px;
    z-index: 1000;
    text-align: center;
    box-shadow: -2px 4px 10px rgba(0, 0, 0, 0.2);
    writing-mode: vertical-rl;
    /* Vertical text */
    text-orientation: upright;
    font-family: var(--font-serif);
    font-weight: 600;
    font-size: 1.1rem;
    letter-spacing: 0.2em;
    text-decoration: none;
    transition: all var(--transition-speed);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    border-radius: 4px 0 0 4px;
    opacity: 0;
    visibility: hidden;
}

.floating-cta.visible {
    opacity: 1;
    visibility: visible;
}

.floating-cta i {
    font-size: 1.5rem;
    margin-bottom: 5px;
    writing-mode: horizontal-tb;
    /* Keep icon horizontal */
}

.floating-cta:hover {
    background-color: var(--accent-color);
    padding-right: 20px;
    /* Slight slide out effect */
}

/* Footer */
.site-footer {
    background-color: #051a35;
    color: rgba(255, 255, 255, 0.6);
    padding: 30px 0;
    text-align: center;
}

/* Responsive specific adjustments */
@media (max-width: 768px) {
    .pricing-table {
        display: block;
        overflow-x: auto;
    }

    .pricing-table th,
    .pricing-table td {
        min-width: 120px;
    }
}

/* Page Headers (for subpages) */
.page-header {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 120px 0 60px;
    /* Top padding accounts for fixed header */
    text-align: center;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 700;
}

/* Company Section */
.company-section {
    background-color: var(--white);
}

.company-info-container {
    max-width: 800px;
    margin: 0 auto;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    border-radius: 10px;
    overflow: hidden;
    background: var(--white);
    border: 1px solid #eee;
}

.company-table {
    width: 100%;
    border-collapse: collapse;
}

.company-table th,
.company-table td {
    padding: 25px;
    border-bottom: 1px solid #f0f0f0;
    text-align: left;
}

.company-table tr:last-child th,
.company-table tr:last-child td {
    border-bottom: none;
}

.company-table th {
    background-color: #f9fbfd;
    width: 30%;
    color: var(--primary-color);
    font-weight: 700;
    white-space: nowrap;
}

.company-table td {
    color: var(--text-color);
}

.service-list li {
    margin-bottom: 5px;
    position: relative;
    padding-left: 15px;
}

.service-list li::before {
    content: '•';
    color: var(--accent-color);
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* Footer Links */
.footer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--white);
    text-decoration: underline;
}

@media (max-width: 1100px) {
    .hero-title {
        font-size: 2.5rem;
        /* Ensure padding on medium screens */
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 1.8rem;
        /* Fit on mobile */
    }

    .hero-title .nowrap-block {
        display: inline;
        /* Allow natural wrapping on mobile screens */
    }

    .hero-content {
        padding: 0 15px;
    }
}

@media (max-width: 600px) {

    .company-table th,
    .company-table td {
        display: block;
        width: 100%;
    }

    .company-table th {
        background-color: transparent;
        padding-bottom: 5px;
        color: var(--accent-color);
    }

    .company-table td {
        padding-top: 0;
        padding-bottom: 30px;
    }
}