/**
 * Dental Career Map - Global Styles
 * Design System B - Japanese UI
 */

:root {
	--bg: #fbfbfd;
	--white: #ffffff;
	--surface: #f5f5f7;
	--surface2: #e8e8ed;
	--text: #1d1d1f;
	--text2: #6e6e73;
	--text3: #86868b;
	--blue: #0071e3;
	--blue-light: #e8f4fd;
	--green: #34c759;
	--green-light: #e8f8ed;
	--teal: #5ac8fa;
	--teal-light: #eaf7fd;
	--purple: #af52de;
	--purple-light: #f3e8fd;
	--orange: #ff9500;
	--orange-light: #fff4e6;
	--red: #ff3b30;
	--red-light: #fde8e7;
	--radius: 20px;
	--radius-sm: 12px;
	--shadow: 0 4px 30px rgba(0, 0, 0, 0.06);
	--shadow-hover: 0 12px 40px rgba(0, 0, 0, 0.1);
}

/* Base Typography */
html {
	scroll-behavior: smooth;
}

body {
	font-family: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	background-color: var(--bg);
	color: var(--text);
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
	font-weight: 700;
	line-height: 1.2;
	margin-top: 0;
}

/* Links */
a {
	color: var(--blue);
	text-decoration: none;
	transition: color 0.2s ease;
}

a:hover {
	color: #0052cc;
	text-decoration: underline;
}

/* Buttons */
button, .btn {
	font-family: 'Noto Sans JP', sans-serif;
	cursor: pointer;
	transition: all 0.2s ease;
	border: none;
	border-radius: var(--radius-sm);
}

button:disabled,
.btn:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

/* Form Elements */
input,
textarea,
select {
	font-family: 'Noto Sans JP', sans-serif;
	color: var(--text);
	background-color: var(--white);
	border: 1px solid var(--surface2);
	border-radius: var(--radius-sm);
	padding: 10px 12px;
	font-size: 14px;
	transition: all 0.2s ease;
}

input:focus,
textarea:focus,
select:focus {
	outline: none;
	border-color: var(--blue);
	box-shadow: 0 0 0 3px var(--blue-light);
}

input[type="checkbox"],
input[type="radio"] {
	cursor: pointer;
	width: 18px;
	height: 18px;
	margin: 0;
}

/* Cards and Containers */
.card,
.post-card,
.listing-card,
.form-section {
	background: var(--white);
	border-radius: var(--radius-sm);
	box-shadow: var(--shadow);
	transition: box-shadow 0.2s ease;
}

.card:hover,
.post-card:hover,
.listing-card:hover {
	box-shadow: var(--shadow-hover);
}

/* Badges */
.badge {
	display: inline-block;
	padding: 6px 12px;
	background-color: var(--blue-light);
	color: var(--blue);
	border-radius: 50px;
	font-size: 12px;
	font-weight: 600;
	white-space: nowrap;
}

.badge.green {
	background-color: var(--green-light);
	color: var(--green);
}

.badge.orange {
	background-color: var(--orange-light);
	color: var(--orange);
}

.badge.purple {
	background-color: var(--purple-light);
	color: var(--purple);
}

.badge.red {
	background-color: var(--red-light);
	color: var(--red);
}

/* Messages */
.form-message,
.message,
.alert {
	padding: 12px 16px;
	border-radius: var(--radius-sm);
	font-size: 14px;
	margin-bottom: 20px;
	display: none;
}

.message.show,
.alert.show {
	display: block;
}

.message.success,
.alert.success {
	background-color: var(--green-light);
	color: var(--green);
	border-left: 4px solid var(--green);
}

.message.error,
.alert.error {
	background-color: var(--red-light);
	color: var(--red);
	border-left: 4px solid var(--red);
}

.message.warning,
.alert.warning {
	background-color: var(--orange-light);
	color: var(--orange);
	border-left: 4px solid var(--orange);
}

.message.info,
.alert.info {
	background-color: var(--blue-light);
	color: var(--blue);
	border-left: 4px solid var(--blue);
}

/* Loading States */
.loading {
	opacity: 0.6;
	pointer-events: none;
}

.spinner {
	display: inline-block;
	width: 20px;
	height: 20px;
	border: 2px solid var(--blue-light);
	border-top-color: var(--blue);
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
}

@keyframes spin {
	to { transform: rotate(360deg); }
}

/* Utility Classes */
.text-center {
	text-align: center;
}

.text-muted {
	color: var(--text2);
}

.text-small {
	font-size: 12px;
}

.mt-0 { margin-top: 0; }
.mt-10 { margin-top: 10px; }
.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }

.mb-0 { margin-bottom: 0; }
.mb-10 { margin-bottom: 10px; }
.mb-20 { margin-bottom: 20px; }
.mb-30 { margin-bottom: 30px; }

.p-20 { padding: 20px; }
.p-30 { padding: 30px; }

.grid-2 {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 20px;
}

.flex {
	display: flex;
	gap: 10px;
}

.flex-between {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 20px;
}

/* Responsive */
@media (max-width: 768px) {
	.grid-2 {
		grid-template-columns: 1fr;
	}

	.flex-between {
		flex-direction: column;
		align-items: flex-start;
	}
}

/* Print Styles */
@media print {
	body {
		background: var(--white);
	}

	.navbar,
	nav,
	button,
	.btn,
	.form-actions {
		display: none;
	}

	.card,
	.post-card {
		box-shadow: none;
		border: 1px solid var(--surface2);
		page-break-inside: avoid;
	}
}
