/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: #1a1a2e;
    line-height: 1.6;
    background: #fff;
}

/* Header & Nav */
header {
    background: #fff;
    border-bottom: 1px solid #e8e8ec;
    position: sticky;
    top: 0;
    z-index: 100;
}
nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo { font-size: 1.5rem; font-weight: 700; text-decoration: none; }
.logo a { text-decoration: none; }
.logo-zero { color: #1a1a2e; }
.logo-di { color: #0078d4; }
.nav-links { list-style: none; display: flex; gap: 2rem; }
.nav-links a {
    text-decoration: none;
    color: #555;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: #0078d4; }

/* Hero */
.hero {
    background: linear-gradient(135deg, #0078d4 0%, #1a1a2e 100%);
    color: #fff;
    text-align: center;
    padding: 5rem 2rem;
}
.hero h1 { font-size: 3rem; font-weight: 700; margin-bottom: 1rem; }
.hero-subtitle {
    font-size: 1.25rem;
    font-weight: 300;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Sections */
section { padding: 4rem 2rem; max-width: 1200px; margin: 0 auto; }
h2 { font-size: 2rem; font-weight: 600; margin-bottom: 2rem; color: #1a1a2e; text-align: center; }
h3 { font-size: 1.25rem; font-weight: 600; margin: 1.5rem 0 0.75rem; color: #1a1a2e; }

/* Products */
.products { background: #f8f9fa; padding: 4rem 2rem; }
.products section { padding: 0; }
.product-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}
.product-card {
    background: #fff;
    border-radius: 12px;
    padding: 3rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.product-icon { margin-bottom: 1rem; line-height: 0; }
.product-icon img { width: 64px; height: 64px; object-fit: contain; }
.product-card h3 { font-size: 1.5rem; color: #0078d4; margin-top: 0; }
.product-card p { color: #555; margin-bottom: 1.5rem; }
.feature-list {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 2rem;
}
.feature-list li {
    padding-left: 1.5rem;
    position: relative;
    color: #444;
    font-size: 0.95rem;
}
.feature-list li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    color: #0078d4;
    font-weight: 700;
}

/* Product Pricing (inline on cards) */
.product-pricing {
    margin-bottom: 1.5rem;
}
.product-pricing .price {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1a1a2e;
}
.product-pricing .price-period {
    font-size: 1rem;
    color: #888;
    font-weight: 400;
}
.product-pricing .price-detail {
    display: block;
    font-size: 0.85rem;
    color: #888;
    margin-top: 0.25rem;
}

/* Pricing Section */
.pricing { background: #fff; padding: 4rem 2rem; }
.pricing-subtitle {
    text-align: center;
    color: #555;
    font-size: 1.1rem;
    max-width: 700px;
    margin: -1rem auto 2rem;
}

/* Billing Toggle */
.billing-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
}
.billing-toggle span {
    font-size: 1rem;
    font-weight: 500;
    color: #888;
    cursor: pointer;
    transition: color 0.2s;
}
.billing-toggle span.active {
    color: #1a1a2e;
    font-weight: 600;
}
.toggle-switch {
    position: relative;
    width: 56px;
    height: 30px;
    background: #0078d4;
    border-radius: 15px;
    cursor: pointer;
    transition: background 0.3s;
}
.toggle-switch::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 24px;
    height: 24px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.3s;
}
.billing-toggle.monthly .toggle-switch::after {
    transform: translateX(26px);
}
.billing-save {
    font-size: 0.8rem;
    background: #e8f5e9;
    color: #2e7d32;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    font-weight: 600;
}
.pricing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto 3rem;
}
.pricing-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 2.5rem 2rem;
    border: 1px solid #e8e8ec;
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.pricing-card .product-icon { margin-bottom: 0.75rem; }
.pricing-card h3 {
    font-size: 1.35rem;
    color: #1a1a2e;
    margin: 0 0 0.25rem;
}
.pricing-desc {
    color: #888;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}
.pricing-amount {
    margin-bottom: 0.5rem;
}
.pricing-amount .price {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1a1a2e;
}
.pricing-amount .price-period {
    font-size: 1.1rem;
    color: #888;
    font-weight: 400;
}
.bundle-savings {
    color: #0078d4;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1rem;
}
.pricing-features {
    list-style: none;
    text-align: left;
    width: 100%;
    margin-bottom: 2rem;
    flex-grow: 1;
}
.pricing-features li {
    padding: 0.5rem 0 0.5rem 1.5rem;
    position: relative;
    color: #444;
    font-size: 0.95rem;
    border-bottom: 1px solid #e8e8ec;
}
.pricing-features li:last-child { border-bottom: none; }
.pricing-features li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    color: #0078d4;
    font-weight: 700;
}
.pricing-card .btn { width: 100%; text-align: center; }

/* Bundle Card */
.bundle-card {
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f0fe 100%);
    border: 2px solid #0078d4;
}
.bundle-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: #0078d4;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.25rem 1.25rem;
    border-radius: 20px;
    white-space: nowrap;
}
.btn-bundle { background: #0078d4; }

/* Pricing Notes */
.pricing-notes {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}
.pricing-note {
    text-align: center;
    padding: 1.5rem;
}
.pricing-note strong {
    display: block;
    color: #1a1a2e;
    font-size: 1rem;
    margin-bottom: 0.5rem;
}
.pricing-note p {
    color: #666;
    font-size: 0.9rem;
    margin: 0;
}
.pricing-note-inline {
    color: #444;
    font-size: 0.95rem;
    line-height: 1.6;
    padding: 4px 0;
}
.pricing-note-inline strong {
    color: #1a1a2e;
}

/* Buttons */
.btn {
    display: inline-block;
    background: #0078d4;
    color: #fff;
    padding: 0.75rem 2rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: background 0.2s;
}
.btn:hover { background: #005a9e; }

/* Contact */
.contact { text-align: center; }
.contact-email {
    font-size: 1.25rem;
    font-weight: 600;
    color: #0078d4;
    margin-top: 1rem;
}

/* Legal Pages */
.legal-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 3rem 2rem;
}
.legal-page h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: #1a1a2e;
}
.last-updated {
    color: #888;
    font-size: 0.9rem;
    margin-bottom: 2.5rem;
}
.legal-page section {
    padding: 0;
    margin-bottom: 2rem;
}
.legal-page section h2 {
    text-align: left;
    font-size: 1.35rem;
    margin-bottom: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e8e8ec;
}
.legal-page section:first-of-type h2 { border-top: none; padding-top: 0; }
.legal-page p { color: #444; margin-bottom: 0.75rem; }
.legal-page ul {
    margin: 0.75rem 0 0.75rem 1.5rem;
    color: #444;
}
.legal-page li { margin-bottom: 0.5rem; }

/* Support Page */
.support-page .hero-subtitle { color: #555; margin-bottom: 3rem; }
.support-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 0;
    max-width: 1200px;
}
.support-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 2rem;
    border: 1px solid #e8e8ec;
}
.support-icon { font-size: 2.5rem; margin-bottom: 1rem; }
.support-card h3 { margin-top: 0; }
.support-card p { color: #555; font-size: 0.95rem; }
.support-card ul { margin: 0.75rem 0 1.5rem 1.25rem; color: #555; font-size: 0.9rem; }
.support-card .btn { font-size: 0.85rem; padding: 0.5rem 1.5rem; }
.doc-list { list-style: none; margin-left: 0 !important; }
.doc-list li { margin-bottom: 0.75rem; }

/* FAQ */
.faq-item {
    border-bottom: 1px solid #e8e8ec;
    padding: 1.5rem 0;
}
.faq-item h3 { color: #0078d4; margin-top: 0; font-size: 1.1rem; }
.faq-item p { color: #555; margin-bottom: 0; }

/* Product Detail Pages */
.product-detail { max-width: 1000px; margin: 0 auto; padding: 3rem 2rem; }
.product-detail-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}
.product-detail-header img { width: 80px; height: 80px; object-fit: contain; }
.product-detail-header h1 { font-size: 2.5rem; color: #1a1a2e; margin: 0; }
.product-detail-header .product-tagline { color: #555; font-size: 1.1rem; margin: 0.25rem 0 0; }
.product-detail-intro { color: #444; font-size: 1.1rem; line-height: 1.8; margin-bottom: 2.5rem; }
.product-detail-cta {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 3rem;
    padding: 1.5rem 2rem;
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f0fe 100%);
    border-radius: 12px;
    border: 1px solid #c8dff5;
}
.product-detail-cta .price { font-size: 2rem; font-weight: 700; color: #1a1a2e; }
.product-detail-cta .price-period { font-size: 1rem; color: #888; }
.product-detail-cta .price-alt { color: #555; font-size: 0.95rem; margin-left: 0.5rem; }
.product-detail-cta .btn { margin-left: auto; }

/* Product Detail CTA with billing toggle */
.product-detail-cta .billing-toggle { margin-bottom: 0.5rem; }
.product-detail-cta .pricing-amount { margin-bottom: 0; }
.product-detail-cta.has-toggle {
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.product-detail-cta.has-toggle .btn { margin-left: 0; }
.toggle-switch.active::after { transform: translateX(26px); }
.product-detail h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a1a2e;
    margin: 2.5rem 0 1rem;
    text-align: left;
}
.product-detail h2:first-of-type { margin-top: 0; }
.screenshot-gallery {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}
.screenshot-item {
    border: 1px solid #e8e8ec;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.screenshot-item img {
    width: 100%;
    display: block;
}
.screenshot-item .screenshot-caption {
    padding: 1rem 1.5rem;
    background: #f8f9fa;
    border-top: 1px solid #e8e8ec;
}
.screenshot-caption h3 { font-size: 1.1rem; color: #1a1a2e; margin: 0 0 0.25rem; }
.screenshot-caption p { color: #555; font-size: 0.9rem; margin: 0; }
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}
.feature-block {
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 10px;
    border: 1px solid #e8e8ec;
}
.feature-block h3 { font-size: 1.05rem; color: #0078d4; margin: 0 0 0.5rem; }
.feature-block p { color: #555; font-size: 0.9rem; margin: 0; }
.product-detail .back-link { display: inline-block; margin-bottom: 1.5rem; color: #0078d4; text-decoration: none; font-size: 0.95rem; }
.product-detail .back-link:hover { text-decoration: underline; }

@media (max-width: 768px) {
    .product-detail-header { flex-direction: column; text-align: center; }
    .product-detail-header h1 { font-size: 1.75rem; }
    .product-detail-cta { flex-direction: column; text-align: center; }
    .product-detail-cta .btn { margin-left: 0; }
    .feature-grid { grid-template-columns: 1fr; }
}

/* Customer Portal */
.portal-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem 2rem;
    min-height: 400px;
}
.portal-status {
    text-align: center;
    padding: 4rem 2rem;
}
.portal-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid #e8e8ec;
    border-top-color: #0078d4;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    animation: portal-spin 0.8s linear infinite;
}
@keyframes portal-spin {
    to { transform: rotate(360deg); }
}
.portal-error-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #fef2f2;
    color: #dc2626;
    font-size: 2rem;
    font-weight: 700;
    line-height: 64px;
    text-align: center;
    margin: 0 auto 1.5rem;
}
.portal-status h3 {
    font-size: 1.5rem;
    color: #1a1a2e;
    margin-bottom: 0.75rem;
}
.portal-status p {
    color: #555;
    max-width: 500px;
    margin: 0 auto;
}
.portal-welcome {
    margin-bottom: 2rem;
    padding: 1.5rem 2rem;
    background: #f0f7ff;
    border-radius: 10px;
    border: 1px solid #c8dff5;
}
.portal-welcome p { margin: 0; color: #333; }
.portal-tenant { font-size: 0.9rem; color: #555 !important; margin-top: 0.25rem !important; }
.portal-products {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}
.portal-product-card {
    background: #fff;
    border-radius: 12px;
    padding: 2rem;
    border: 1px solid #e8e8ec;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
}
.portal-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    gap: 0.75rem;
}
.portal-card-header h3 {
    font-size: 1.15rem;
    color: #1a1a2e;
    margin: 0;
}
.portal-status-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.2rem 0.75rem;
    border-radius: 20px;
    white-space: nowrap;
    flex-shrink: 0;
}
.portal-status-active { background: #e8f5e9; color: #2e7d32; }
.portal-status-trial { background: #e3f2fd; color: #1565c0; }
.portal-status-grace { background: #fff3e0; color: #e65100; }
.portal-status-expired { background: #fef2f2; color: #dc2626; }
.portal-status-cancelled { background: #f5f5f5; color: #666; }
.portal-card-details {
    flex-grow: 1;
    margin-bottom: 1.5rem;
}
.portal-card-details p {
    margin: 0.25rem 0;
    font-size: 0.9rem;
    color: #555;
}
.portal-download-btn {
    width: 100%;
    text-align: center;
    cursor: pointer;
    border: none;
    font-family: inherit;
}
.portal-coming-soon {
    text-align: center;
    color: #888;
    font-size: 0.9rem;
    font-style: italic;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 6px;
    margin: 0;
}
.portal-license-expired {
    text-align: center;
    color: #dc2626;
    font-size: 0.9rem;
    padding: 0.75rem;
    background: #fef2f2;
    border-radius: 6px;
    margin: 0;
}
.portal-license-expired a { color: #0078d4; }
.portal-no-products {
    text-align: center;
    color: #555;
    padding: 2rem;
    grid-column: 1 / -1;
}
.portal-help {
    padding: 1.5rem 2rem;
    background: #f8f9fa;
    border-radius: 10px;
    border: 1px solid #e8e8ec;
}
.portal-help h3 { margin: 0 0 0.5rem; font-size: 1.1rem; color: #1a1a2e; }
.portal-help p { margin: 0; color: #555; font-size: 0.9rem; }
.portal-help a { color: #0078d4; }

@media (max-width: 768px) {
    .portal-products { grid-template-columns: 1fr; }
    .portal-card-header { flex-direction: column; align-items: flex-start; }
}

/* Footer */
footer {
    background: #1a1a2e;
    color: #aab;
    padding: 2.5rem 2rem;
    margin-top: 4rem;
}
.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.footer-brand p { font-size: 0.85rem; margin-top: 0.5rem; }
.footer-links { display: flex; gap: 2rem; }
.footer-links a {
    color: #aab;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}
.footer-links a:hover { color: #0078d4; }

/* App Download Section */
.app-download {
    text-align: center;
    padding: 40px 32px;
    background: linear-gradient(135deg, #f0f6ff 0%, #e8f0fe 100%);
    border-radius: 12px;
    margin-bottom: 48px;
}
.app-download h2 {
    margin: 0 0 8px;
    font-size: 1.5rem;
    color: #1a1a1a;
}
.app-download p {
    margin: 0 0 24px;
    color: #555;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 24px;
}
.app-badges {
    display: flex;
    gap: 16px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}
.app-badge img {
    height: 48px;
    width: auto;
    transition: opacity 0.2s;
}
.app-badge:hover img {
    opacity: 0.8;
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .feature-list { grid-template-columns: 1fr; }
    .product-cards { grid-template-columns: 1fr; }
    .pricing-cards { grid-template-columns: 1fr; }
    .pricing-notes { grid-template-columns: 1fr; }
    .nav-links { gap: 1rem; font-size: 0.85rem; }
    .footer-content { flex-direction: column; gap: 1.5rem; text-align: center; }
    .support-options { grid-template-columns: 1fr; }
}
