/* ==========================================================================
   专属贺卡 · 设计系统
   主题：油田夜色 / Oilfield Night
   —— 深井夜蓝 + 井场金 + 石油红，工程图纸式的细线与噪点质感
   纯静态、零外部依赖（无 CDN、无构建）
   ========================================================================== */

/* --------------------------------------------------------------------------
   1 · 设计变量
   -------------------------------------------------------------------------- */
:root {
	/* 夜色 */
	--ink-950: #04080d;
	--ink-900: #060c13;
	--ink-850: #08111a;
	--ink-800: #0b1520;
	--ink-750: #0e1a26;
	--ink-700: #12202e;

	/* 石油红 */
	--oil-600: #8c2a1a;
	--oil-500: #b8341f;
	--oil-400: #d2492f;
	--oil-300: #e4694d;

	/* 井场金 */
	--gold-700: #8a6526;
	--gold-600: #b08a3f;
	--gold-500: #cf9f52;
	--gold-400: #e9b45c;
	--gold-300: #f3d59a;
	--gold-200: #fbeccb;

	/* 钢蓝 */
	--steel-500: #3c5f7d;
	--steel-400: #5f89a9;

	/* 文字 */
	--text: #e9eef4;
	--text-dim: #a7b6c4;
	--text-mute: #6d7f90;
	--on-paper: #2b2620;
	--on-paper-dim: #4b4238;
	--on-paper-mute: #8a7a63;

	/* 线条与面板 */
	--hair: rgba(233, 180, 92, 0.15);
	--hair-2: rgba(233, 180, 92, 0.30);
	--panel: rgba(255, 255, 255, 0.035);
	--panel-2: rgba(255, 255, 255, 0.06);

	/* 阴影 */
	--shadow-xl: 0 40px 90px -40px rgba(0, 0, 0, 0.95);
	--shadow-glow: 0 0 70px -20px rgba(233, 180, 92, 0.30);

	/* 字体 */
	--font-sans: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei",
		"Hiragino Sans GB", system-ui, -apple-system, "Segoe UI", sans-serif;
	--font-serif: "Songti SC", "STSong", "Source Han Serif SC", "Noto Serif SC",
		"SimSun", serif;
	--font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas,
		"Liberation Mono", monospace;

	/* 圆角 */
	--r-sm: 10px;
	--r-md: 14px;
	--r-lg: 20px;
	--r-xl: 26px;

	/* 缓动 */
	--ease: cubic-bezier(0.2, 0.75, 0.25, 1);

	/* 噪点纹理（内联，无外部请求） */
	--grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='.55'/%3E%3C/svg%3E");
}

/* --------------------------------------------------------------------------
   2 · 基础重置
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

body,
h1,
h2,
h3,
p,
figure {
	margin: 0;
}

h1,
h2,
h3 {
	font-weight: 700;
	line-height: 1.3;
}

img,
svg {
	display: block;
	max-width: 100%;
}

button {
	font: inherit;
	color: inherit;
	background: none;
	border: 0;
	padding: 0;
	cursor: pointer;
}

a {
	color: inherit;
	text-decoration: none;
}

/* 隐藏内联图标精灵，不占布局 */
.sprite {
	position: absolute;
	width: 0;
	height: 0;
	overflow: hidden;
}

/* 线性图标基类（stroke 由 symbol 内的 g 声明） */
.ico {
	width: 1.15em;
	height: 1.15em;
	flex: none;
}

body {
	min-height: 100vh;
	color: var(--text);
	font-family: var(--font-sans);
	font-size: 16px;
	line-height: 1.6;
	overflow-x: hidden;
	background-color: var(--ink-900);
	background-image:
		radial-gradient(1000px 620px at 15% -5%, rgba(233, 180, 92, 0.10), transparent 60%),
		radial-gradient(900px 640px at 92% 105%, rgba(184, 52, 31, 0.14), transparent 62%),
		radial-gradient(1500px 950px at 50% 45%, #0b1621 0%, #070e16 58%, #04080d 100%);
	background-attachment: fixed;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

::selection {
	background: rgba(233, 180, 92, 0.28);
	color: var(--gold-200);
}

:focus-visible {
	outline: 2px solid var(--gold-400);
	outline-offset: 3px;
	border-radius: 4px;
}

::-webkit-scrollbar {
	width: 10px;
	height: 10px;
}

::-webkit-scrollbar-track {
	background: var(--ink-950);
}

::-webkit-scrollbar-thumb {
	background: linear-gradient(180deg, #3d2e16, #1d2833);
	border: 2px solid var(--ink-950);
	border-radius: 8px;
}

::-webkit-scrollbar-thumb:hover {
	background: linear-gradient(180deg, #5c4420, #243443);
}

/* --------------------------------------------------------------------------
   3 · 背景特效层
   -------------------------------------------------------------------------- */
.fx {
	position: fixed;
	inset: 0;
	pointer-events: none;
}

/* 工程图纸网格 */
.fx--grid {
	z-index: 0;
	background-image:
		linear-gradient(rgba(255, 255, 255, 0.030) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255, 255, 255, 0.030) 1px, transparent 1px);
	background-size: 68px 68px;
	-webkit-mask-image: radial-gradient(ellipse 82% 68% at 50% 45%, #000 32%, transparent 100%);
	mask-image: radial-gradient(ellipse 82% 68% at 50% 45%, #000 32%, transparent 100%);
	opacity: 0.6;
}

/* 暗角 */
.fx--vignette {
	z-index: 0;
	background: radial-gradient(125% 105% at 50% 48%, transparent 52%, rgba(0, 0, 0, 0.62) 100%);
}

/* 胶片颗粒 */
.fx--grain {
	z-index: 9000;
	background-image: var(--grain);
	opacity: 0.035;
	mix-blend-mode: soft-light;
}

/* --------------------------------------------------------------------------
   4 · 通用面板
   -------------------------------------------------------------------------- */
.panel {
	position: relative;
	border: 1px solid var(--hair);
	border-radius: var(--r-xl);
	background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015));
	box-shadow: var(--shadow-xl), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

/* 暖纸面板（贺卡背面、信封、弹窗共用） */
.paper {
	position: relative;
	color: var(--on-paper);
	border: 1px solid rgba(184, 52, 31, 0.18);
	border-radius: var(--r-xl);
	background-image:
		radial-gradient(120% 70% at 50% 0%, rgba(255, 255, 255, 0.85), transparent 58%),
		linear-gradient(165deg, #faf5e9 0%, #f2e9d7 52%, #e9dcc4 100%);
	box-shadow: 0 50px 120px -40px rgba(0, 0, 0, 0.95), inset 0 1px 0 #fff;
}

/* --------------------------------------------------------------------------
   5 · 按钮
   -------------------------------------------------------------------------- */
.btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 13px 26px;
	border: 1px solid var(--hair-2);
	border-radius: 999px;
	color: var(--gold-200);
	font-size: 14.5px;
	font-weight: 600;
	letter-spacing: 0.08em;
	white-space: nowrap;
	background-image: linear-gradient(180deg, rgba(233, 180, 92, 0.15), rgba(233, 180, 92, 0.04));
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
	transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease),
		border-color 0.35s var(--ease), background-color 0.35s var(--ease),
		color 0.35s var(--ease);
}

.btn:hover {
	border-color: rgba(243, 213, 154, 0.6);
	box-shadow: 0 14px 40px -18px rgba(233, 180, 92, 0.75),
		inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.btn--gold {
	color: #1d1405;
	border-color: transparent;
	background-image: linear-gradient(180deg, var(--gold-300) 0%, var(--gold-400) 45%, var(--gold-600) 100%);
	box-shadow: 0 14px 36px -16px rgba(233, 180, 92, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.btn--gold:hover {
	box-shadow: 0 20px 46px -16px rgba(233, 180, 92, 0.95), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.btn--oil {
	color: #fff4f0;
	border-color: transparent;
	background-image: linear-gradient(180deg, var(--oil-300) 0%, var(--oil-400) 45%, var(--oil-600) 100%);
	box-shadow: 0 14px 36px -16px rgba(184, 52, 31, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.btn--oil:hover {
	box-shadow: 0 20px 46px -16px rgba(184, 52, 31, 1), inset 0 1px 0 rgba(255, 255, 255, 0.34);
}

/* 水波扩散特效（沿用原版 .btn-effect 行为） */
.btn-effect {
	position: relative;
	overflow: hidden;
	isolation: isolate;
}

.btn-effect::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 0;
	height: 0;
	z-index: -1;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.30);
	transform: translate(-50%, -50%);
	transition: width 0.6s ease, height 0.6s ease;
}

.btn-effect:hover::before {
	width: 320px;
	height: 320px;
}

/* --------------------------------------------------------------------------
   6 · 备案信息行（两页共用）
   -------------------------------------------------------------------------- */
.beian-container {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 10px 20px;
	width: 100%;
	max-width: 1200px;
	margin: 0 auto;
}

.gongan-group {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.beian-logo {
	height: 17px;
	width: auto;
	vertical-align: middle;
	opacity: 0.92;
}

.gongan-link,
.icp-link {
	display: inline-flex;
	align-items: center;
	gap: 2px;
	color: var(--text-mute);
	font-family: var(--font-mono);
	font-size: 12.5px;
	letter-spacing: 0.01em;
	transition: color 0.22s ease;
}

.gongan-link:hover,
.icp-link:hover {
	color: var(--gold-300);
}

/* --------------------------------------------------------------------------
   7 · 弹层（两页共用的遮罩基类）
   -------------------------------------------------------------------------- */
.overlay {
	position: fixed;
	inset: 0;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: rgba(3, 7, 11, 0.74);
	-webkit-backdrop-filter: blur(9px) saturate(1.1);
	backdrop-filter: blur(9px) saturate(1.1);
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.32s var(--ease), visibility 0.32s var(--ease);
}

.overlay.is-open {
	opacity: 1;
	visibility: visible;
}

.overlay > * {
	transform: translateY(14px) scale(0.985);
	transition: transform 0.42s var(--ease);
}

.overlay.is-open > * {
	transform: none;
}

/* 纸面板上的关闭按钮 */
.close-btn {
	position: absolute;
	top: 12px;
	right: 12px;
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	color: var(--on-paper-mute);
	font-size: 20px;
	line-height: 1;
	transition: background-color 0.22s ease, color 0.22s ease;
}

.close-btn:hover {
	background: rgba(184, 52, 31, 0.10);
	color: var(--oil-500);
}

/* --------------------------------------------------------------------------
   8 · 无障碍 / 动效偏好
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.001ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.001ms !important;
	}

	[data-reveal] {
		opacity: 1 !important;
		transform: none !important;
	}
}
