templates2.Saas.Next/app/globals.css
w4c-templates 6538da5797
Some checks are pending
CI / quality (push) Waiting to run
chore(template): publish Saas.Next
2026-10-11 23:24:56 +03:00

400 lines
12 KiB
CSS

@import "tailwindcss";
/* ── Self-hosted variable fonts ────────────────────────────────────────────
No third-party requests and no flash of the system fallback: the marketing
surface is drawn in the same type everywhere. Geist for UI/display, Geist
Mono for micro-type (eyebrows, indices, numbers), Instrument Serif kept
available for case-specific editorial headings. */
@font-face {
font-family: "Geist";
font-style: normal;
font-weight: 100 900;
font-display: swap;
src: url("/fonts/geist-latin.woff2") format("woff2");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
font-family: "Geist";
font-style: normal;
font-weight: 100 900;
font-display: swap;
src: url("/fonts/geist-latin-ext.woff2") format("woff2");
unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
font-family: "Geist Mono";
font-style: normal;
font-weight: 100 900;
font-display: swap;
src: url("/fonts/geist-mono-latin.woff2") format("woff2");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
font-family: "Geist Mono";
font-style: normal;
font-weight: 100 900;
font-display: swap;
src: url("/fonts/geist-mono-latin-ext.woff2") format("woff2");
unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
font-family: "Instrument Serif";
font-style: normal;
font-weight: 400;
font-display: swap;
src: url("/fonts/instrument-serif-latin.woff2") format("woff2");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
font-family: "Instrument Serif";
font-style: italic;
font-weight: 400;
font-display: swap;
src: url("/fonts/instrument-serif-italic-latin.woff2") format("woff2");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Theme is toggled by a `.dark` class on <html> (see ThemeProvider). */
@custom-variant dark (&:where(.dark, .dark *));
@theme {
--color-brand-50: #eef2ff;
--color-brand-100: #e0e7ff;
--color-brand-200: #c7d2fe;
--color-brand-400: #818cf8;
--color-brand-500: #6366f1;
--color-brand-600: #4f46e5;
--color-brand-700: #4338ca;
/* A single warm accent, used sparingly (eyebrows, marks, highlights). */
--color-accent-300: #fcd34d;
--color-accent-400: #fbbf24;
--color-accent-500: #f59e0b;
--font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
--font-display: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
--font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
--font-serif: "Instrument Serif", ui-serif, Georgia, "Times New Roman", serif;
--radius-xl: 14px;
--radius-2xl: 18px;
--radius-3xl: 26px;
}
@layer base {
:root {
--surface: #ffffff;
--surface-raised: #ffffff;
--canvas: #f4f5f8;
--surface-muted: #eef0f6;
--border: #e4e6ef;
--border-strong: #d2d5e1;
--text: #0a0b14;
--text-muted: #5a6070;
--text-faint: #868da0;
/* Brand ink that stays legible on the canvas in both themes. */
--accent-ink: #4f46e5;
--warn-ink: #b45309;
/* Inner top-edge highlight that fakes a beveled surface. */
--edge: rgba(255, 255, 255, 0.75);
--shadow-color: 10 11 20;
color-scheme: light;
}
.dark {
--surface: #07090f;
--surface-raised: #0d1017;
--canvas: #04050a;
--surface-muted: #10141d;
--border: #1b2130;
--border-strong: #2a3247;
--text: #edeff5;
--text-muted: #98a1b6;
--text-faint: #6b7488;
--accent-ink: #a5b4fc;
--warn-ink: #fcd34d;
--edge: rgba(255, 255, 255, 0.06);
--shadow-color: 0 0 0;
color-scheme: dark;
}
* {
border-color: var(--border);
}
html,
body {
background: var(--surface);
color: var(--text);
}
body {
font-family: var(--font-sans);
font-feature-settings: "cv11" 1, "ss01" 1;
-webkit-font-smoothing: antialiased;
text-rendering: optimizeLegibility;
}
h1,
h2,
h3,
h4 {
text-wrap: balance;
}
p {
text-wrap: pretty;
}
a {
color: inherit;
}
}
@layer components {
.page {
@apply mx-auto w-full max-w-6xl px-5;
}
.surface {
background: var(--surface);
}
.muted {
color: var(--text-muted);
}
/* Real, elevated card — a surface with a bevel edge, not a tinted box. */
.card {
@apply rounded-2xl border p-6;
background: var(--surface);
border-color: var(--border);
box-shadow: 0 1px 2px rgb(var(--shadow-color) / 0.04), 0 12px 28px -20px rgb(var(--shadow-color) / 0.16);
}
/* Elevated panel used across the marketing site — a real card, not a tinted box. */
.panel {
@apply rounded-2xl border;
background: var(--surface-raised);
border-color: var(--border);
box-shadow:
inset 0 1px 0 0 var(--edge),
0 1px 2px rgb(var(--shadow-color) / 0.04),
0 22px 44px -28px rgb(var(--shadow-color) / 0.24);
}
/* Frosted-glass chip/card for dark and image bands. */
.glass {
@apply rounded-2xl border backdrop-blur-md;
background: color-mix(in srgb, var(--surface) 68%, transparent);
border-color: color-mix(in srgb, var(--border) 80%, transparent);
}
/* Mono micro-label: section indices, category marks, table headers. */
.kicker {
@apply inline-flex items-center gap-2 font-mono text-[11px] font-medium uppercase tracking-[0.22em];
color: var(--text-faint);
}
.eyebrow {
@apply inline-flex items-center gap-2 text-xs font-semibold uppercase tracking-[0.18em];
}
.chip {
@apply inline-flex items-center gap-1.5 rounded-full border px-2.5 py-1 text-xs font-medium;
background: var(--surface);
border-color: var(--border);
}
/* Hairline divider that fades at the edges. */
.rule {
height: 1px;
background: linear-gradient(to right, transparent, var(--border-strong) 12%, var(--border-strong) 88%, transparent);
}
/* All button variants share the base rule (Tailwind v4 cannot @apply a custom class). */
.btn,
.btn-primary,
.btn-secondary,
.btn-ghost,
.btn-danger {
@apply inline-flex items-center justify-center gap-2 rounded-xl px-4 py-2 text-sm font-medium transition duration-200;
}
.btn:disabled,
.btn-primary:disabled,
.btn-secondary:disabled,
.btn-ghost:disabled,
.btn-danger:disabled {
@apply cursor-not-allowed opacity-60;
}
.btn-primary {
@apply text-white;
background: linear-gradient(180deg, color-mix(in srgb, var(--color-brand-500) 92%, white), var(--color-brand-600));
box-shadow:
inset 0 1px 0 0 rgba(255, 255, 255, 0.22),
0 1px 2px rgb(var(--shadow-color) / 0.2),
0 12px 24px -12px color-mix(in srgb, var(--color-brand-600) 75%, transparent);
}
.btn-primary:hover:not(:disabled) {
background: linear-gradient(180deg, var(--color-brand-500), var(--color-brand-700));
transform: translateY(-1px);
box-shadow:
inset 0 1px 0 0 rgba(255, 255, 255, 0.24),
0 2px 4px rgb(var(--shadow-color) / 0.2),
0 18px 32px -14px color-mix(in srgb, var(--color-brand-600) 80%, transparent);
}
.btn-primary:active:not(:disabled) {
transform: translateY(0);
}
.btn-secondary {
@apply border;
background: var(--surface-raised);
color: var(--text);
border-color: var(--border-strong);
box-shadow: inset 0 1px 0 0 var(--edge);
}
.btn-secondary:hover:not(:disabled) {
background: var(--surface-muted);
}
.btn-ghost {
color: var(--text-muted);
}
.btn-ghost:hover:not(:disabled) {
background: var(--surface-muted);
color: var(--text);
}
.btn-danger {
@apply bg-red-600 text-white;
}
.btn-danger:hover:not(:disabled) {
@apply bg-red-700;
}
.label {
@apply mb-1 block text-sm font-medium;
}
.input {
@apply w-full rounded-xl border px-3 py-2 text-sm outline-none;
background: var(--surface);
color: var(--text);
border-color: var(--border);
}
.input:focus {
border-color: var(--color-brand-500);
box-shadow: 0 0 0 3px color-mix(in srgb, var(--color-brand-500) 25%, transparent);
}
.badge {
@apply inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-semibold;
}
}
@layer utilities {
/* Faint blueprint grid behind the hero. */
.bg-grid {
background-image: linear-gradient(to right, color-mix(in srgb, var(--border) 70%, transparent) 1px, transparent 1px),
linear-gradient(to bottom, color-mix(in srgb, var(--border) 70%, transparent) 1px, transparent 1px);
background-size: 56px 56px;
}
.glow-brand {
background: radial-gradient(closest-side, color-mix(in srgb, var(--color-brand-500) 42%, transparent), transparent 72%);
}
.text-gradient {
background: linear-gradient(120deg, var(--text) 8%, var(--color-brand-600) 55%, #7c3aed 96%);
-webkit-background-clip: text;
background-clip: text;
color: transparent;
}
.shadow-soft {
box-shadow:
inset 0 1px 0 0 var(--edge),
0 1px 2px rgb(var(--shadow-color) / 0.04),
0 30px 60px -36px rgb(var(--shadow-color) / 0.3);
}
/* Display type: optical-size tracking and a tight, confident leading. */
.font-display,
.display {
font-family: var(--font-display);
letter-spacing: -0.028em;
line-height: 0.98;
}
.tabular {
font-variant-numeric: tabular-nums;
}
.animate-marquee {
animation: marquee 34s linear infinite;
}
/* Film grain — a barely-there texture that keeps flat bands from looking plastic. */
.grain::after {
content: "";
position: absolute;
inset: 0;
pointer-events: none;
opacity: 0.5;
mix-blend-mode: overlay;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
}
@keyframes marquee {
from {
transform: translateX(0);
}
to {
transform: translateX(-50%);
}
}
/* Scroll reveal — opt-in via [data-reveal]; the observer in the page adds .is-in.
Gated on `html.js` so the hidden state never applies without JavaScript. */
.js [data-reveal] {
opacity: 0;
transform: translateY(16px);
transition:
opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
transition-delay: var(--reveal-delay, 0ms);
}
.js [data-reveal].is-in {
opacity: 1;
transform: none;
}
/* Visible keyboard focus everywhere (WCAG 2.4.7). */
:focus-visible {
outline: 2px solid var(--color-brand-500);
outline-offset: 2px;
border-radius: 4px;
}
@media (prefers-reduced-motion: reduce) {
* {
animation-duration: 0.01ms !important;
transition-duration: 0.01ms !important;
}
[data-reveal] {
opacity: 1;
transform: none;
}
}
html {
scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
html {
scroll-behavior: auto;
}
}