/* base.css — design tokens, reset, typography baseline.
   Shared across entire site (root + all products + blog + tools). */

/* Self-hosted fonts — eliminates render-blocking Google Fonts CDN request */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/inter-v20-latin-regular.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/inter-v20-latin-500.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/inter-v20-latin-600.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/inter-v20-latin-700.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 800; font-display: swap; src: url('../fonts/inter-v20-latin-800.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 900; font-display: swap; src: url('../fonts/inter-v20-latin-900.woff2') format('woff2'); }
@font-face { font-family: 'Rajdhani'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/rajdhani-v17-latin-700.woff2') format('woff2'); }

:root {
    /* Brand colors — dark mono from shinobiapps-landing */
    --bg-primary: #0f0f0f;
    --bg-secondary: #1a1a1a;
    --bg-tertiary: #242424;
    --bg-elevated: #2a2a2a;

    --text-primary: #f5f5f5;
    --text-secondary: #b8b8b8;
    --text-muted: #888888;
    --text-disabled: #555555;

    --border-primary: #2e2e2e;
    --border-secondary: #404040;

    --accent: #4a9eff;
    --accent-hover: #6fb2ff;
    --accent-bg: rgba(74, 158, 255, 0.1);

    --success: #4ade80;
    --warning: #fbbf24;
    --danger: #ef4444;

    /* Spacing scale */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;

    /* Typography */
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;
    --font-display: 'Rajdhani', 'Inter', system-ui, sans-serif;
    --font-mono: 'JetBrains Mono', 'SF Mono', Consolas, monospace;

    --text-base: 1rem;
    --text-sm: 0.875rem;
    --text-xs: 0.75rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 2rem;
    --text-4xl: 2.5rem;
    --text-5xl: 3.5rem;

    /* Radii */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.5);

    /* Layout */
    --container-max: 1200px;
    --nav-height: 64px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    scrollbar-gutter: stable;
}

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.15s ease;
}

a:hover {
    color: var(--accent-hover);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
}

h1 { font-size: var(--text-5xl); }
h2 { font-size: var(--text-4xl); }
h3 { font-size: var(--text-3xl); }
h4 { font-size: var(--text-2xl); }
h5 { font-size: var(--text-xl); }
h6 { font-size: var(--text-lg); }

p {
    margin-bottom: var(--space-md);
}

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

/* Button primitives */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-lg);
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: 600;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    line-height: 1.4;
}

.btn-primary {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: white;
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border-color: var(--border-secondary);
}

.btn-secondary:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* Main layout */
.site-main {
    min-height: calc(100vh - var(--nav-height));
    padding-top: var(--nav-height);
}

/* Hero (used by root + product landings) */
.hero {
    padding: var(--space-3xl) 0;
    text-align: center;
}

.hero-title {
    font-size: clamp(var(--text-3xl), 5vw, var(--text-5xl));
    margin-bottom: var(--space-lg);
    letter-spacing: -0.02em;
}

.hero-lead {
    font-size: var(--text-xl);
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto var(--space-xl);
}

.hero-ctas {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* Products grid (root landing showcase) */
.products-grid-section {
    padding: var(--space-2xl) 0;
}

.products-grid-section h2 {
    text-align: center;
    margin-bottom: var(--space-2xl);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-lg);
}

.product-card {
    display: flex;
    flex-direction: column;
    padding: var(--space-xl);
    background: var(--bg-secondary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    transition: border-color 0.15s ease, transform 0.15s ease;
}

.product-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
    color: var(--text-primary);
}

.product-card h2,
.product-card h3 {
    font-size: var(--text-2xl);
    margin-bottom: var(--space-sm);
}

.product-card p {
    color: var(--text-secondary);
    flex: 1;
}

.product-card-cta {
    color: var(--accent);
    font-weight: 600;
    margin-top: var(--space-md);
}

.placeholder-notice {
    padding: var(--space-xl) 0;
    border-top: 1px dashed var(--border-primary);
    margin-top: var(--space-2xl);
}
