/*
Theme: Proposal Theme - Front Page Styles
Description: Styles specific to the front page (hero, search, results sections)
Version: 2.5.1
*/

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
	background: linear-gradient(270deg, #0cb1c1, #3948b9);
	background-size: 200% 200%;
	animation: heroGradient 10s ease infinite;
	color: var(--white);
	padding: 60px 0 80px;
	position: relative;
	overflow: hidden;
}

@keyframes heroGradient {
	0% {
		background-position: 0% 50%;
	}

	50% {
		background-position: 100% 50%;
	}

	100% {
		background-position: 0% 50%;
	}
}

.hero-section::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
	opacity: 0.5;
	z-index: 0;
}

/* Semi-transparent gradient overlay for better text readability */
.hero-section::after {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: linear-gradient(270deg, rgba(12, 177, 193, 0.8), rgba(57, 72, 185, 0.8));
	z-index: 1;
	pointer-events: none;
}

#hero-canvas {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 0;
	filter: url('#goo');
}

.hero-content {
	position: relative;
	z-index: 2;
	text-align: center;
	max-width: 800px;
	margin: 0 auto;
	text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-title {
	font-size: 2.5rem;
	font-weight: 800;
	margin-bottom: 16px;
	letter-spacing: -0.02em;
}

.hero-subtitle {
	font-size: 1.125rem;
	opacity: 0.9;
	margin-bottom: 32px;
	line-height: 1.7;
}

.hero-stats {
	display: flex;
	justify-content: center;
	gap: 48px;
	margin-top: 40px;
}

.hero-stats .stat-number,
.hero-stats .stat-label {
	color: white;
}

.stat-item {
	text-align: center;
}

.stat-number {
	font-size: 2.5rem;
	font-weight: 700;
	display: block;
}

.stat-label {
	font-size: 0.875rem;
	opacity: 0.8;
}

@media screen and (max-width: 768px) {
	.hero-section {
		padding: 40px 0 40px;
	}

	.hero-title {
		font-size: 1.5rem;
		margin-bottom: 12px;
	}

	.hero-subtitle {
		font-size: 0.875rem;
		margin-bottom: 5px;
		line-height: 1.5;
	}

	.hero-stats {
		gap: 16px;
		margin-top: 5px;
	}

	.stat-number {
		font-size: 1.5rem;
	}

	.stat-label {
		font-size: 0.75rem;
	}
}

/* ==========================================================================
   Search Section  
   ========================================================================== */
.search-section {
	margin-top: 24px;
	position: relative;
	z-index: 10;
	padding-bottom: 40px;
}

.search-box {
	background: var(--white);
	border-radius: var(--radius-xl);
	box-shadow: var(--shadow-xl);
	padding: 24px;
}

.search-main {
	display: flex;
	gap: 12px;
	margin-bottom: 16px;
}

.search-input-wrapper {
	flex: 1;
	position: relative;
}

.search-input-wrapper svg {
	position: absolute;
	left: 16px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--gray-400);
}

.search-input-wrapper .search-input {
	width: 100%;
	padding: 14px 16px 14px 40px;
	font-size: 1rem;
	border: 2px solid var(--gray-200);
	border-radius: var(--radius-lg);
	transition: var(--transition);
	background: var(--white);
}

@media screen and (max-width: 768px) {
	.search-input-wrapper .search-input {
		padding-left: 48px;
	}
}

.search-input-wrapper .search-input:focus {
	outline: none;
	border-color: var(--primary);
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-input-wrapper .search-input::placeholder {
	color: var(--gray-400);
}

.btn-search {
	-webkit-tap-highlight-color: transparent;
	outline: none;
	padding: 14px 32px;
	background: var(--primary);
	color: var(--white);
	font-size: 1rem;
	font-weight: 600;
	border: none;
	border-radius: var(--radius-lg);
	cursor: pointer;
	transition: var(--transition);
	display: flex;
	align-items: center;
	gap: 8px;
	white-space: nowrap;
}

.btn-search:hover {
	background: var(--primary-dark);
	transform: translateY(-1px);
	box-shadow: var(--shadow-md);
}

.btn-search:active {
	transform: translateY(0);
}

.btn-search.btn-clear-condition {
	background: var(--gray-500);
}

.btn-search.btn-clear-condition:hover {
	background-color: var(--gray-600);
}

.btn-search.loading {
	opacity: 0.7;
	pointer-events: none;
}

.btn-search .spinner {
	display: none;
	width: 18px;
	height: 18px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-top-color: white;
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
}

.btn-search.loading .spinner {
	display: block;
}

.btn-search.loading .btn-text {
	display: none;
}

@keyframes spin {
	to {
		transform: rotate(360deg);
	}
}

.status-spinner {
	display: inline-block;
	width: 14px;
	height: 14px;
	border: 2px solid var(--gray-200);
	border-top-color: var(--primary);
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
	margin-right: 6px;
	vertical-align: middle;
	position: relative;
	top: -1px;
}

/* PC Search Status */
.search-status-display {
	display: none;
	/* Default hidden */
	align-items: center;
	margin-bottom: 12px;
	font-size: 0.875rem;
	color: var(--gray-600);
	font-weight: 500;
}

@media screen and (min-width: 769px) {
	.search-status-display {
		display: flex;
		/* Show on PC */
	}
}

.filters-toggle {
	display: flex;
	align-items: center;
	gap: 6px;
	background: none;
	border: none;
	color: var(--gray-600);
	font-size: 0.875rem;
	cursor: pointer;
	padding: 8px 0;
	transition: var(--transition);
}

.filters-toggle:hover {
	color: var(--primary);
}

.filters-toggle svg {
	transition: transform 0.3s ease;
}

.filters-toggle.active svg {
	transform: rotate(180deg);
}

.filters-panel {
	display: none;
	padding-top: 16px;
	border-top: 1px solid var(--gray-100);
	margin-top: 16px;
	animation: slideDown 0.3s ease;
}

.filters-panel.show {
	display: block;
}

@media screen and (max-width: 768px) {
	.is-full .filters-toggle {
		display: none !important;
	}

	.is-full .filters-panel {
		display: block !important;
		margin-top: 0;
		border-top: none;
		padding-top: 0;
	}

	.is-full .save-search-area {
		display: block !important;
		/* Always display on SP (Full) */
	}
}

@keyframes slideDown {
	from {
		opacity: 0;
		transform: translateY(-10px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.filters-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
	gap: 16px;
}

.filter-group label {
	display: block;
	font-size: 0.75rem;
	font-weight: 600;
	color: var(--gray-500);
	text-transform: uppercase;
	letter-spacing: 0.05em;
	margin-bottom: 6px;
}

.count-text {
	font-size: 0.85em;
	color: var(--gray-500);
	margin-left: 4px;
	font-weight: 400;
}

.filter-select {
	width: 100%;
	padding: 10px 12px;
	font-size: 0.9375rem;
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	background: var(--white);
	cursor: pointer;
	transition: var(--transition);
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
}

.filter-select:focus {
	outline: none;
	border-color: var(--primary);
}

.dropdown-btn {
	width: 260px;
}

@media screen and (max-width: 768px) {
	.dropdown-btn {
		width: 100%;
	}
}

/* Date input additional layout */
.date-inputs {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: nowrap;
	/* No line breaks */
}

.filter-input-date {
	width: auto;
	flex: 1;
	min-width: 0;
	/* Allow flex item shrink */
	padding: 10px 12px;
	font-size: 0.9375rem;
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	background: var(--white);
	transition: var(--transition);
}

@media screen and (max-width: 768px) {
	.date-inputs {
		gap: 4px;
	}

	.filter-input-date {
		padding: 8px;
		font-size: 14px;
	}
}

.filter-input-date:focus {
	outline: none;
	border-color: var(--primary);
}

.date-sep {
	color: var(--gray-400);
	font-size: 0.9rem;
	flex-shrink: 0;
}



/* Budget filter layout adjustment (inline display for upper limit) */
.budget-upper-group {
	display: flex;
	align-items: center;
	gap: 4px;
	flex: 1;
	min-width: 0;
}

.budget-upper-group .filter-input-date {
	width: 100%;
}

.budget-unit {
	font-size: 0.8em;
	color: #666;
	white-space: nowrap;
	flex-shrink: 0;
	padding-left: 4px;
}

@media screen and (max-width: 768px) {
	.budget-upper-group {
		gap: 2px;
	}
}

.active-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 16px;
}

@media screen and (max-width: 768px) {
	.active-filters {
		gap: 16px !important;
	}

	.active-filters .filter-chip {
		margin-bottom: 7px;
		margin-right: 5px;
	}
}

.filter-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	background: var(--primary);
	color: var(--white);
	font-size: 0.8125rem;
	border-radius: 20px;
	animation: fadeIn 0.2s ease;
}

.filter-chip button {
	background: none;
	border: none;
	color: inherit;
	cursor: pointer;
	padding: 0;
	display: flex;
	opacity: 0.8;
}

.filter-chip button:hover {
	opacity: 1;
}

.btn-clear-all {
	background: var(--gray-100);
	color: var(--gray-600);
}

@keyframes fadeIn {
	from {
		opacity: 0;
		transform: scale(0.9);
	}

	to {
		opacity: 1;
		transform: scale(1);
	}
}

/* ==========================================================================
   Results Section
   ========================================================================== */
.results-section {
	padding: 40px 0 80px;
}

/* Control area layout adjustment */
.results-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 24px;
	flex-wrap: wrap;
	gap: 16px;
}

.results-count {
	font-size: 0.9375rem;
	color: var(--gray-600);
}

.results-count strong {
	color: var(--dark);
	font-weight: 700;
}

/* Control group */
.results-controls {
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
}

.controls-group {
	display: flex;
	align-items: center;
	gap: 16px;
}

.control-item {
	display: flex;
	align-items: center;
	gap: 8px;
}

.control-item label {
	font-size: 0.8125rem;
	color: var(--gray-500);
	white-space: nowrap;
	font-weight: 500;
}

/* Select box unified (with filter) */
.control-select {
	padding: 8px 32px 8px 12px;
	font-size: 0.875rem;
	color: var(--gray-700);
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	background-color: var(--white);
	cursor: pointer;
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 10px center;
	transition: var(--transition);
}

.control-select:focus {
	outline: none;
	border-color: var(--primary);
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Layout toggle design adjustment */
.layout-toggle {
	display: flex;
	background: var(--white);
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	overflow: hidden;
}

.layout-btn {
	background: transparent;
	border: none;
	padding: 8px 12px;
	color: var(--gray-500);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.2s ease;
}

.layout-btn:not(:last-child) {
	border-right: 1px solid var(--gray-200);
}

.layout-btn:hover {
	color: var(--primary);
	background: var(--gray-50);
}

.layout-btn.active {
	background: var(--gray-100);
	color: var(--primary);
	box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.03);
}

/* ==========================================================================
   Results Grid & Cards
   ========================================================================== */
.results-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
	gap: 24px;
	min-height: 200px;
}

.results-grid.loading {
	opacity: 0.5;
	pointer-events: none;
}

.proposal-card {
	background: var(--white);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow);
	padding: 24px;
	transition: var(--transition);
	position: relative;
	display: flex;
	flex-direction: column;
	border: 1px solid var(--gray-100);
	cursor: pointer;
}

.proposal-card:hover {
	box-shadow: var(--shadow-lg);
	transform: translateY(-2px);
	border-color: var(--gray-200);
}

.proposal-card.expired {
	opacity: 0.6;
}

.proposal-card.urgent {
	border-left: 4px solid var(--danger);
}

.proposal-card.soon {
	border-left: 4px solid var(--warning);
}

/* Badge */
.deadline-badge {
	position: absolute;
	top: 16px;
	right: 16px;
	padding: 4px 10px;
	font-size: 0.6875rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	border-radius: 4px;
}

.deadline-badge.expired {
	background: var(--gray-100);
	color: var(--gray-600);
}

.deadline-badge.urgent {
	background: #fef2f2;
	color: var(--danger);
}

.deadline-badge.soon {
	background: #fffbeb;
	color: var(--warning);
}

/* Card Content */
.proposal-title {
	font-size: 1.0625rem;
	font-weight: 600;
	line-height: 1.5;
	margin-bottom: 12px;
}

.proposal-title a {
	color: var(--dark);
	display: block;
	font-size: 16px;
	width: 100%;
	position: relative;
	z-index: 2;
}

.proposal-tags a {
	position: relative;
	z-index: 2;
}

.proposal-title a:hover {
	color: var(--dark);
}

.results-grid.grid-view .proposal-title a:hover {
	color: var(--dark);
}

.proposal-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	margin-bottom: 12px;
}

.meta-item {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 0.8125rem;
	color: var(--gray-600);
}

.meta-item svg {
	flex-shrink: 0;
	color: var(--gray-400);
}

.meta-item.budget {
	color: var(--success);
	font-weight: 600;
}

.meta-item.budget svg {
	color: var(--success);
}

.proposal-summary {
	font-size: 0.875rem;
	color: var(--gray-600);
	line-height: 1.7;
	margin-bottom: 16px;
	flex-grow: 1;
}

/* Tags */
.proposal-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-bottom: 16px;
}

.tag {
	display: inline-block;
	padding: 4px 10px;
	font-size: 0.75rem;
	background: var(--gray-100);
	color: var(--gray-600);
	border-radius: 4px;
}

.tag.industry {
	background: #dbeafe;
	color: var(--primary-dark);
}

.tag-hash {
	color: var(--primary);
	font-size: 0.8125rem;
	text-decoration: none;
	margin-right: 8px;
	font-weight: 500;
}

.tag-hash:hover {
	text-decoration: underline;
	color: var(--primary-dark);
}

.btn-detail {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	padding: 12px;
	font-size: 0.875rem;
	font-weight: 600;
	color: var(--white);
	background: var(--primary);
	border-radius: var(--radius);
	transition: var(--transition);
	margin-top: auto;
	position: relative;
	z-index: 2;
}

.btn-detail:hover {
	background: var(--primary-dark);
	color: var(--white);
}

.proposal-card a.stop-propagation {
	position: relative;
	z-index: 2;
}

/* ==========================================================================
   List View Styles (Adjusted)
   ========================================================================== */
.results-grid.list-view {
	grid-template-columns: 1fr !important;
}

.results-grid.list-view .proposal-card {
	flex-direction: column;
	/* Vertical layout removed */
	align-items: stretch;
	/* Full width */
	padding: 24px;
	gap: 12px;
	/* Element spacing adjusted */
	display: flex;
}

/* Deadline, urgency, etc. badge */
.results-grid.list-view .deadline-badge {
	position: absolute;
	top: 16px;
	right: 16px;
	margin: 0;
	order: -1;
	/* Absolute positioned OK for consistency, but order for DOM */
}

/* Title */
.results-grid.list-view .proposal-title {
	margin-bottom: 0;
	flex: initial;
	font-size: 1.125rem;
	order: 1;
}

/* Meta information (Publisher, Deadline, Budget) */
.results-grid.list-view .proposal-meta {
	flex-direction: row;
	/* Back to vertical layout */
	gap: 16px;
	width: 100%;
	flex-shrink: 0;
	order: 2;
	/* Below title */
	margin-bottom: 4px;
	border-left: none;
	/* Remove left border */
	padding-left: 0;
}

/* Summary text */
.results-grid.list-view .proposal-summary {
	order: 3;
	margin-bottom: 4px;
	display: block;
}

/* Tag area */
.results-grid.list-view .proposal-tags {
	order: 4;
	margin-bottom: 0;
}

/* Detail button */
.results-grid.list-view .btn-detail {
	order: 5;
	width: auto;
	align-self: flex-end;
	/* Right aligned */
	margin-top: 8px;
	padding: 10px 24px;
}

/* ==========================================================================
   No Results & Pagination
   ========================================================================== */
.no-results {
	grid-column: 1 / -1;
	text-align: center;
	padding: 80px 20px;
	color: var(--gray-500);
}

.no-results svg {
	margin-bottom: 16px;
}

.no-results p {
	font-size: 1.125rem;
	margin-bottom: 8px;
}

.no-results .sub {
	font-size: 0.875rem;
	color: var(--gray-500);
}

.pagination {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 8px;
	margin-top: 48px;
}

.page-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 12px;
	font-size: 0.875rem;
	font-weight: 500;
	color: var(--gray-600);
	background: var(--white);
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	cursor: pointer;
	transition: var(--transition);
}

.page-btn:hover {
	background: var(--gray-50);
	border-color: var(--gray-300);
}

.page-btn.active {
	background: var(--primary);
	color: var(--white);
	border-color: var(--primary);
}

.page-btn:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

/* ==========================================================================
   Hero News Area (Added to Hero section)
   ========================================================================== */
.hero-news-area {
	margin-top: 48px;
	background: rgba(255, 255, 255, 0.1);
	/* Translucent background */
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: var(--radius-lg);
	padding: 20px 24px;
	text-align: left;
	/* Text alignment left */
	max-width: 800px;
	margin-left: auto;
	margin-right: auto;
	backdrop-filter: blur(4px);
	/* Blur effect */
}

.hero-news-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 12px;
	padding-bottom: 8px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.hero-news-label {
	font-size: 0.9375rem;
	font-weight: 700;
	color: var(--white);
	display: flex;
	align-items: center;
	gap: 8px;
}

.hero-news-label::before {
	content: '';
	display: block;
	width: 4px;
	height: 16px;
	background: var(--white);
	/* Accent color */
	border-radius: 2px;
}

.hero-news-link {
	font-size: 0.8125rem;
	color: rgba(255, 255, 255, 0.8);
	text-decoration: none;
	position: relative;
	display: inline-block;
	padding-bottom: 2px;
}

.hero-news-link:hover {
	color: var(--white);
	text-decoration: none;
}

.hero-news-link::after {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	width: 0;
	height: 1px;
	background-color: var(--white);
	transition: width 0.3s ease;
}

.hero-news-link:hover::after {
	width: 100%;
}

/* Note: Carousel for news items, for display only */
.hero-news-slider-container {
	overflow: hidden;
	width: 100%;
}

.hero-news-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.hero-news-item {
	display: flex;
	align-items: baseline;
	padding: 8px 0;
	font-size: 0.9375rem;
	color: var(--white);
}

.hero-news-date {
	font-family: monospace;
	color: rgba(255, 255, 255, 0.7);
	margin-right: 16px;
	font-size: 0.875rem;
	flex-shrink: 0;
}

.hero-news-title {
	color: var(--white);
	text-decoration: none;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	position: relative;
	display: inline-block;
	padding-bottom: 2px;
}

.hero-news-item a.hero-news-title:hover,
.hero-news-title:hover {
	color: var(--white);
	text-decoration: none;
	opacity: 1;
}

/* Animated Underline */
.hero-news-item a.hero-news-title::after {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	width: 0;
	height: 1px;
	background-color: var(--white);
	transition: width 0.3s ease;
}

.hero-news-item a.hero-news-title:hover::after {
	width: 100%;
}

@media (max-width: 768px) {
	.hero-news-item {
		flex-direction: column;
		gap: 2px;
	}

	.hero-news-date {
		font-size: 0.75rem;
	}

	.hero-news-title {
		white-space: normal;
		/* On SP, allow wrapping */
	}
}
/* ==========================================================================
   Custom Dropdown & Date Range (Added in Phase 2)
   ========================================================================== */
/* ==========================================================================
   Note: Custom dropdown & date range input styles
   ========================================================================== */

/* Date range input */
.date-inputs {
	display: flex;
	align-items: center;
	gap: 8px;
}

.filter-input-date {
	flex: 1;
	padding: 10px 12px;
	font-size: 0.9375rem;
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	background: var(--white);
	color: var(--gray-700);
}

.date-sep {
	color: var(--gray-500);
}

/* Custom dropdown for multiple selections */
.custom-dropdown {
	position: relative;
	width: 100%;
}

.dropdown-btn {
	width: 100%;
	padding: 10px 12px;
	font-size: 0.9375rem;
	text-align: left;
	background: var(--white);
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	color: var(--gray-700);
	cursor: pointer;
	position: relative;
	transition: var(--transition);
}

.dropdown-btn::after {
	content: '';
	position: absolute;
	right: 12px;
	top: 50%;
	transform: translateY(-50%);
	width: 0;
	height: 0;
	border-left: 5px solid transparent;
	border-right: 5px solid transparent;
	border-top: 5px solid var(--gray-500);
}

.dropdown-btn:hover,
.dropdown-btn.active {
	border-color: var(--primary);
}

/* Dropdown content */
.dropdown-content {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	background: var(--white);
	border: 1px solid var(--gray-200);
	border-radius: var(--radius);
	box-shadow: var(--shadow-lg);
	z-index: 50;
	max-height: 250px;
	overflow-y: auto;
	margin-top: 4px;
	padding: 8px 0;
}

.dropdown-content.show {
	display: block;
}

.checkbox-item {
	display: flex;
	align-items: center;
	padding: 8px 12px;
	cursor: pointer;
	transition: background 0.1s;
	font-size: 0.875rem;
	color: var(--gray-700);
}

.checkbox-item:hover {
	background: var(--gray-50);
}

.checkbox-item input[type="checkbox"] {
	margin-right: 8px;
	accent-color: var(--primary);
	width: 16px;
	height: 16px;
	transform: translateY(3px);
}

/* Badge for selected item count */
.badge-count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: var(--primary);
	color: white;
	font-size: 10px;
	height: 18px;
	min-width: 18px;
	border-radius: 9px;
	padding: 0 5px;
	margin-left: 6px;
	vertical-align: middle;
}

@media (max-width: 480px) {
	.date-inputs {
		flex-direction: column;
		align-items: stretch;
	}

	.date-sep {
		text-align: center;
		transform: rotate(90deg);
		height: 20px;
	}
}

/* Note: Dropdown button styles when disabled */
.dropdown-btn.disabled {
	background-color: #f3f4f6;
	/* var(--gray-100) */
	color: #9ca3af;
	/* var(--gray-400) */
	cursor: not-allowed;
	opacity: 0.7;
	pointer-events: none;
	/* Disable click */
}

/* Note: Filter chip display for selected criteria */
.filter-chip.chip-gray {
	background-color: var(--gray-200);
	color: var(--gray-600);
	border: 1px solid var(--gray-300);
}

.filter-chip.chip-gray button {
	color: var(--gray-500);
}

.filter-chip.chip-gray button:hover {
	color: var(--danger);
}


/* ==========================================================================
   Note: Save Search feature styles
   ========================================================================== */
.save-search-area {
	display: none;
	/* Hidden by default */
	border-top: 1px dashed var(--gray-300);
	margin-top: 24px;
	padding-top: 16px;
	animation: slideDown 0.3s ease;
	/* Animation added */
}

/* Class for showing */
.save-search-area.show {
	display: block;
}

.save-btn-wrapper {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 12px;
}

.btn-save-search {
	background-color: var(--success);
	/* Right aligned */
	color: #fff;
	border: none;
	padding: 8px 16px;
	border-radius: var(--radius);
	font-size: 0.875rem;
	font-weight: 600;
	cursor: pointer;
	transition: background 0.2s;
}

.btn-save-search:hover {
	background-color: #059669;
	/* 蟆代＠豼・＞邱・*/
}

.saved-searches-list {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	font-size: 0.875rem;
}

.saved-search-item {
	color: var(--primary);
	text-decoration: underline;
	cursor: pointer;
	background: none;
	border: none;
	padding: 0;
	font-family: inherit;
}

.saved-search-item:hover {
	color: var(--primary-dark);
}

.saved-search-remove {
	color: var(--gray-400);
	margin-left: 4px;
	cursor: pointer;
	text-decoration: none;
	font-size: 0.75rem;
}

.saved-search-remove:hover {
	color: var(--danger);
}

/* 笘・ｿｽ蜉: 菫晏ｭ俶擅莉ｶ縺ｮ邱ｨ髮・い繧､繧ｳ繝ｳ */
.saved-search-edit {
	color: var(--gray-400);
	margin-left: 6px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	vertical-align: middle;
}

.saved-search-edit:hover {
	color: var(--primary);
}



/* ==========================================================================
   Front Page Layout (2 Column) & Column Sidebar
   ========================================================================== */
.front-layout-grid {
	display: grid;
	grid-template-columns: 1fr 320px;
	gap: 32px;
	align-items: start;
}

.main-search-area {
	/* 讀懃ｴ｢繝懊ャ繧ｯ繧ｹ縺ｯ譌｢蟄倥・繧ｹ繧ｿ繧､繝ｫ繧堤ｶ呎価縺励▽縺､繧ｰ繝ｪ繝・ラ蜀・↓蜿弱ａ繧・*/
}

/* Column Sidebar Styles */
.column-sidebar {
	background: rgba(255, 255, 255, 0.6);
	backdrop-filter: blur(8px);
	border: 1px solid var(--gray-200);
	border-radius: var(--radius-xl);
	padding: 24px;
	box-shadow: var(--shadow);
}

.column-section {
	margin-bottom: 32px;
}

.column-header {
	font-size: 1rem;
	font-weight: 700;
	color: var(--dark);
	border-bottom: 2px solid var(--primary);
	padding-bottom: 8px;
	margin-bottom: 16px;
}

.column-list {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.column-card {
	display: flex;
	gap: 12px;
	text-decoration: none;
	color: inherit;
	transition: var(--transition);
	background: var(--white);
	padding: 8px;
	border-radius: var(--radius);
	border: 1px solid transparent;
}

.column-card:hover {
	background: var(--white);
	transform: translateX(4px);
	border-color: var(--gray-200);
	box-shadow: var(--shadow-sm);
}

.column-thumb {
	width: 80px;
	height: 60px;
	flex-shrink: 0;
	border-radius: 4px;
	overflow: hidden;
	background: var(--gray-100);
}

.column-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.no-thumb-placeholder {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 10px;
	color: var(--gray-500);
	background: var(--gray-100);
}

.column-info {
	flex: 1;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.column-title {
	font-size: 0.875rem;
	font-weight: 600;
	color: var(--dark);
	line-height: 1.4;
	margin-bottom: 4px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.column-date {
	font-size: 0.75rem;
	color: var(--gray-500);
}

.btn-column-all {
	display: block;
	width: 100%;
	padding: 12px;
	text-align: center;
	background: var(--white);
	color: var(--primary);
	border: 1px solid var(--primary);
	border-radius: var(--radius);
	font-size: 0.875rem;
	font-weight: 600;
	transition: var(--transition);
}

.btn-column-all:hover {
	background: var(--primary);
	color: var(--white);
}

@media (max-width: 900px) {
	.front-layout-grid {
		grid-template-columns: 1fr;
	}

	.column-sidebar {
		margin-top: 24px;
	}
}

/* ==========================================================================
   Front Page Layout
   ========================================================================== */
.container.front-page-layout {
	max-width: 1600px;
	/* Increase width for 2-column layout */
}

.front-page-layout {
	display: grid;
	gap: 32px;
	padding-bottom: 80px;
	align-items: start;
}

/* Mobile Default: Stacked (Main then Sidebar) */
.layout-main {
	min-width: 0;
}

.layout-sidebar {
	min-width: 0;
}

.layout-main .search-section,
.layout-main .results-section {
	padding-top: 0;
	padding-bottom: 24px;
	margin-top: 0;
}

/* Sidebar Styles */
.column-section {
	background: var(--white);
	padding: 24px;
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow);
	margin-bottom: 24px;
	border: 1px solid var(--gray-100);
}

.column-header {
	font-size: 1.125rem;
	font-weight: 700;
	margin-bottom: 16px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--gray-100);
}

.column-list {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.column-card {
	display: flex;
	gap: 12px;
	align-items: flex-start;
}

.column-card:hover .column-title {
	color: var(--primary);
}

.column-thumb {
	width: 80px;
	height: 60px;
	flex-shrink: 0;
	background: var(--gray-100);
	border-radius: var(--radius);
	overflow: hidden;
}

.column-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.no-thumb-placeholder {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 0.625rem;
	color: var(--gray-500);
	background: var(--gray-50);
}

.column-info {
	flex: 1;
	min-width: 0;
}

.column-title {
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.5;
	margin-bottom: 4px;
	color: var(--dark);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.column-date {
	font-size: 0.75rem;
	color: var(--gray-500);
	display: block;
}

.btn-column-all {
	display: block;
	text-align: center;
	font-size: 0.875rem;
	color: var(--primary);
	font-weight: 600;
	margin-top: 16px;
}

.btn-column-all:hover {
	text-decoration: underline;
}

/* PC View (> 900px): 2 Column Side-by-Side */
@media (min-width: 900px) {
	.front-page-layout {
		grid-template-columns: 1fr 300px;
		margin-top: 40px;
	}

	.layout-sidebar {
		position: sticky;
		top: 80px;
	}
}

/* ==========================================================================
   SP Layout Adjustment: Overlap Search Box
   ========================================================================== */
@media (max-width: 768px) {
	.search-section {
		margin-top: -60px;
		position: relative;
		z-index: 20;
		padding-left: 10px;
		padding-right: 10px;
	}
}

/* Search form checkbox responsive text */
.label-text-sp {
	display: none;
}

@media (max-width: 768px) {
	.label-text-pc {
		display: none;
	}

	.label-text-sp {
		display: inline;
	}
}

/* ==========================================================================
   Cookie Consent Popup
   ========================================================================== */
.cookie-consent-popup {
	position: fixed;
	bottom: 20px;
	left: 20px;
	background: var(--white);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-xl);
	padding: 24px;
	width: 460px;
	z-index: 9000;
	border: 1px solid var(--gray-200);
	animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
	from {
		transform: translateY(20px);
		opacity: 0;
	}

	to {
		transform: translateY(0);
		opacity: 1;
	}
}

.cookie-text {
	font-size: 0.875rem;
	color: var(--gray-700);
	margin-bottom: 20px;
	line-height: 1.6;
}

.cookie-buttons {
	display: flex;
	gap: 10px;
	justify-content: space-between;
}
