/* =================================================================
   CODENOSYS SOFTWARE SOLUTIONS SERVICE PAGE STYLES
   ================================================================= */

/* --- 1. Hero Section --- */
.ss-hero {
    position: relative;
    padding: 180px 0 100px;
    background: radial-gradient(circle at top, rgba(6, 214, 160, 0.08) 0%, var(--color-bg) 75%);
    overflow: hidden;
}

.ss-hero__bg {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

.holo-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(6, 214, 160, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(6, 214, 160, 0.08) 1px, transparent 1px);
    background-size: 50px 50px;
    mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
    transform: perspective(600px) rotateX(60deg) translateY(-80px) scale(1.8);
    opacity: 0.5;
    animation: gridMove 25s linear infinite;
}

@keyframes gridMove {
    0% { background-position: 0 0; }
    100% { background-position: 0 50px; }
}

.holo-glow {
    position: absolute;
    top: -20%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(6, 214, 160, 0.15) 0%, transparent 70%);
    filter: blur(80px);
}

.ss-hero__layout {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 2;
}

.ss-hero__content {
    max-width: 680px;
}

.ss-hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(6, 214, 160, 0.1);
    border: 1px solid rgba(6, 214, 160, 0.2);
    border-radius: 100px;
    padding: 6px 16px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #06d6a0;
    margin-bottom: 24px;
}

.ss-hero__badge .live-dot {
    width: 6px;
    height: 6px;
    background: #06d6a0;
    border-radius: 50%;
    box-shadow: 0 0 10px #06d6a0;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.ss-hero .title {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 6vw, 4.2rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    color: #fff;
    letter-spacing: -0.02em;
}

.ss-hero .subtitle {
    font-size: 1.15rem;
    color: var(--color-text-muted);
    margin-bottom: 40px;
    line-height: 1.65;
}

.ss-hero__actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

/* Button Classes Override */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(45deg, #06d6a0, #118ab2);
    color: #fff;
    padding: 16px 36px;
    border-radius: 50px;
    font-weight: 600;
    box-shadow: 0 10px 30px rgba(6, 214, 160, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: none;
    border: none;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(6, 214, 160, 0.45);
    color: #fff;
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #f9f9f9;
    padding: 16px 36px;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: none;
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
}

/* --- Interactive Canvas HUD --- */
.ss-canvas-hud {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.node-control-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.node-control-panel label {
    font-family: monospace;
    font-size: 0.75rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
}

.slider-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Custom styled range input */
.node-slider, .calc-slider {
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
}

.node-slider::-webkit-slider-thumb, .calc-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #06d6a0;
    cursor: pointer;
    box-shadow: 0 0 10px #06d6a0;
    transition: transform 0.2s ease;
}

.node-slider::-webkit-slider-thumb:hover, .calc-slider::-webkit-slider-thumb:hover {
    transform: scale(1.25);
}

.node-count-indicator {
    font-family: monospace;
    font-size: 0.85rem;
    font-weight: 700;
    color: #06d6a0;
    min-width: 65px;
    text-align: right;
}

.canvas-viewport {
    height: 180px;
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.node-svg {
    width: 100%;
    height: 100%;
}

.svg-node {
    transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}

.node-circle {
    fill: rgba(6, 214, 160, 0.15);
    stroke: #06d6a0;
    stroke-width: 2;
    transition: all 0.3s;
}

.node-circle.gateway {
    fill: rgba(17, 138, 178, 0.2);
    stroke: #118ab2;
}

.node-circle.active {
    fill: rgba(6, 214, 160, 0.3);
    filter: drop-shadow(0 0 8px #06d6a0);
}

.node-line {
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 1.5;
    stroke-dasharray: 4;
    transition: all 0.3s;
}

.node-line.active {
    stroke: #06d6a0;
    stroke-dasharray: 0;
    filter: drop-shadow(0 0 2px #06d6a0);
}

.canvas-metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 15px;
}

.metric-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.metric-item .label {
    font-size: 0.75rem;
    font-family: monospace;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.metric-item strong {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: #fff;
}

/* --- Global Section Headers --- */
.section-tag {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #06d6a0;
    margin-bottom: 16px;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 20px;
    color: #fff;
    letter-spacing: -0.02em;
}

.section-desc {
    font-size: 1.1rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    margin-bottom: 40px;
    max-width: 680px;
}

/* Header Alignments */
.ss-calculator__header, .ss-microservices__header {
    text-align: center;
    margin-bottom: 60px;
}

.ss-calculator__header .section-desc, .ss-microservices__header .section-desc {
    margin-left: auto;
    margin-right: auto;
}

/* --- 2. SaaS Seat Tax Calculator --- */
.ss-calculator {
    padding: 120px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.ss-calculator__header {
    text-align: center;
    margin-bottom: 60px;
}

.calculator-card {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 32px;
    padding: 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.2);
}

.sliders-pane {
    display: flex;
    flex-direction: column;
    gap: 35px;
}

.slider-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.slider-header span {
    font-size: 0.95rem;
    font-weight: 600;
    color: #fff;
}

.slider-header strong {
    font-family: monospace;
    font-size: 1rem;
    color: #06d6a0;
}

.results-pane {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.result-box {
    padding: 30px 20px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.06);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: all 0.3s;
}

.result-box.waste {
    border-color: rgba(255, 95, 86, 0.15);
    background: linear-gradient(135deg, rgba(255, 95, 86, 0.02), transparent);
}

.result-box.savings {
    border-color: rgba(6, 214, 160, 0.15);
    background: linear-gradient(135deg, rgba(6, 214, 160, 0.02), transparent);
}

.result-box span {
    font-size: 0.78rem;
    text-transform: uppercase;
    font-family: monospace;
    color: var(--color-text-muted);
}

.result-box strong {
    font-family: var(--font-heading);
    font-size: 1.8rem;
}

.result-box.waste strong {
    color: #ff5f56;
    text-shadow: 0 0 10px rgba(255, 95, 86, 0.2);
}

.result-box.savings strong {
    color: #06d6a0;
    text-shadow: 0 0 10px rgba(6, 214, 160, 0.2);
}

/* --- 3. Architecture Editor --- */
.ss-editor-section {
    padding: 120px 0;
    background: #02040a;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.ss-editor__grid {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 60px;
    align-items: center;
}

.workspace-tabs {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 40px;
}

.workspace-tab {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    background: rgba(255,255,255,0.01);
    border: 1px solid rgba(255,255,255,0.05);
    padding: 20px;
    border-radius: 16px;
    text-align: left;
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
    cursor: pointer;
}

.workspace-tab .num {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--color-text-muted);
    transition: color 0.3s;
}

.workspace-tab h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 6px;
}

.workspace-tab p {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    line-height: 1.4;
}

.workspace-tab:hover {
    border-color: rgba(6, 214, 160, 0.2);
    background: rgba(6, 214, 160, 0.02);
}

.workspace-tab.active {
    border-color: #06d6a0;
    background: rgba(6, 214, 160, 0.05);
    box-shadow: 0 10px 30px rgba(6, 214, 160, 0.08);
}

.workspace-tab.active .num {
    color: #06d6a0;
}

/* Terminal IDE Viewport */
.ss-editor__viewport {
    height: 400px;
}

.terminal-editor {
    background: #05070c;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.editor-header {
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 14px 20px;
    display: flex;
    align-items: center;
    position: relative;
}

.editor-header .circles {
    display: flex;
    gap: 8px;
}

.editor-header .circle {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.circle.red { background: #ff5f56; }
.circle.yellow { background: #ffbd2e; }
.circle.green { background: #27c93f; }

.editor-header .file-name {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    font-family: monospace;
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.editor-body {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
}

.editor-body pre {
    margin: 0;
    height: 100%;
}

.editor-body code {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.88rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.7);
    display: block;
    white-space: pre-wrap;
    transition: opacity 0.2s ease;
}

.editor-body code .kw {
    color: #4cc9f0;
    font-weight: bold;
}

.editor-body code .str {
    color: #ffd166;
}

.editor-body code .comment {
    color: rgba(255, 255, 255, 0.35);
    font-style: italic;
}

/* --- 4. Modular Microservice Board --- */
.ss-microservices {
    padding: 120px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.ss-microservices__header {
    text-align: center;
    margin-bottom: 60px;
}

.board-viewport {
    height: 480px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.005);
    overflow: hidden;
}

.board-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.wire-path {
    fill: none;
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 2;
    stroke-dasharray: 8, 8;
    animation: flowDash 30s linear infinite;
    transition: all 0.4s ease;
}

.wire-path.active {
    stroke: #06d6a0;
    stroke-width: 2.5;
    animation: flowDashActive 8s linear infinite;
    filter: drop-shadow(0 0 5px #06d6a0);
}

@keyframes flowDash {
    0% { stroke-dashoffset: 0; }
    100% { stroke-dashoffset: -1000; }
}

@keyframes flowDashActive {
    0% { stroke-dashoffset: 0; }
    100% { stroke-dashoffset: -1000; }
}

.board-grid {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
}

.board-node {
    position: absolute;
    background: #05070c;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
    text-align: center;
    width: 220px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    cursor: default;
}

.board-node .node-icon {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: #fff;
    margin: 0 auto 12px;
    transition: all 0.3s;
}

.board-node h4 {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 6px;
}

.board-node span {
    font-size: 0.78rem;
    color: var(--color-text-muted);
}

/* Specific Positions */
.board-node.node-main {
    top: 50%;
    left: 20%;
    transform: translate(-50%, -50%);
    border-color: rgba(17, 138, 178, 0.25);
}

.board-node.node-main .node-icon {
    background: rgba(17, 138, 178, 0.15);
    color: #118ab2;
}

.board-node.node-sub {
    left: 70%;
    transform: translate(-50%, -50%);
}

#nodeERP { top: 20%; }
#nodeCron { top: 50%; }
#nodeMigration { top: 80%; }

/* Hovers */
.board-node:hover {
    border-color: #06d6a0;
    transform: translate(-50%, -55%);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.board-node:hover .node-icon {
    background: rgba(6, 214, 160, 0.15);
    color: #06d6a0;
}

.board-node.node-main:hover {
    border-color: #118ab2;
}

/* --- 5. Technical Specifications HUD --- */
.ss-specs {
    padding: 80px 0;
    background: rgba(0, 0, 0, 0.15);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.ss-specs__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    text-align: center;
}

.spec-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.spec-value {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    color: #06d6a0;
    text-shadow: 0 0 15px rgba(6, 214, 160, 0.15);
}

.spec-card h4 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
    color: #fff;
}

.spec-card p {
    font-size: 0.88rem;
    color: var(--color-text-muted);
    line-height: 1.4;
}

/* --- 6. FAQ & CTA --- */
.ss-faq {
    padding: 120px 0;
}

.ui-faq__grid {
    display: grid;
    grid-template-columns: 1.25fr 0.75fr;
    gap: 60px;
    align-items: flex-start;
}

.ui-section-header h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 40px;
}

.faq-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding: 24px 0;
}

.faq-trigger {
    width: 100%;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #fff;
    font-size: 1.15rem;
    font-weight: 600;
    text-align: left;
    transition: color 0.3s;
}

.faq-trigger i {
    font-size: 1.4rem;
    color: #06d6a0;
    transition: transform 0.4s ease;
}

.faq-item.active .faq-trigger i {
    transform: rotate(45deg);
}

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.faq-content p {
    padding-top: 16px;
    font-size: 0.98rem;
    line-height: 1.6;
    color: var(--color-text-muted);
}

/* CTA Card */
.ss-cta-box {
    background: linear-gradient(135deg, rgba(6, 214, 160, 0.03), rgba(17, 138, 178, 0.03));
    border: 1px solid rgba(6, 214, 160, 0.15);
    border-radius: 32px;
    padding: 50px 40px;
    text-align: center;
    box-shadow: 0 20px 45px rgba(6, 214, 160, 0.05);
}

.ss-cta-box h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 16px;
}

.ss-cta-box p {
    font-size: 0.98rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    margin-bottom: 32px;
}

/* --- 7. Responsive Adaptations --- */
@media (max-width: 1024px) {
    .ss-hero__layout {
        grid-template-columns: 1fr;
        gap: 50px;
    }

    .ss-hero__visual {
        max-width: 500px;
        margin: 0 auto;
        width: 100%;
    }

    .ss-calculator__grid {
        grid-template-columns: 1fr;
    }

    .calculator-card {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .ss-editor__grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }

    .ss-editor__viewport {
        height: 360px;
    }

    .board-viewport {
        height: auto;
        border: none;
        background: none;
    }

    .board-svg {
        display: none;
    }

    .board-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 20px;
        height: auto;
    }

    .board-node {
        position: static !important;
        width: 100% !important;
        transform: none !important;
    }

    .ss-specs__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }

    .ui-faq__grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }
}

@media (max-width: 768px) {
    .ss-hero {
        padding: 140px 0 80px;
    }

    .results-pane {
        grid-template-columns: 1fr;
    }

    .ss-specs__grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}
