/* Modern Light Theme - Desktop Only */
:root {
	--primary: #4A90E2;
	--primary-dark: #357ABD;
	--success: #5CB85C;
	--warning: #F0AD4E;
	--danger: #D9534F;
	--info: #5BC0DE;
	--light: #F8F9FA;
	--dark: #343A40;
	--border: #DEE2E6;
	--shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
	--shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.12);
}

body {
	background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
	min-height: 100vh;
	/* padding: 20px 15px; */
	padding: 0 15px 20px 15px;
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
	font-size: 16px;
}

.container-custom {
	max-width: 1100px;
	margin: 3rem auto 0 auto;
}

/* Header Styles */
h1 {
	font-size: 2rem;
	font-weight: 600;
	color: var(--dark);
	margin-top: 0;
	margin-bottom: 1.5rem;
	text-align: center;
}


h2 {
	font-size: 1.5rem;
	font-weight: 600;
	color: var(--dark);
	text-align: center;
	margin: 2rem 0 1rem 0;
}


/* Button Styles */
button,
.btn {
	padding: 0.5rem 1rem;
	border-radius: 6px;
	border: none;
	font-size: 0.95rem;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s ease;
	min-width: 80px;
	height: 38px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

button:hover,
.btn:hover {
	transform: translateY(-1px);
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

button.trailer-btn {
	background: #5CB85C;
	color: #000;
	min-width: 60px;
}

button.trailer-btn i {
	color: white;
}

button.trailer-btn:hover {
	background: #4cae4c;
}

button.imdb-btn {
	background: #F5C518;
	color: #000;
}

button.imdb-btn:hover {
	background: #E6B800;
}

button.guide-btn {
	background: var(--info);
	color: white;
}

button.guide-btn:hover {
	background: #46B8DA;
}

button.google-btn {
	background: white;
	border: 1px solid var(--border);
	color: var(--dark);
}

button.google-btn:hover {
	background: var(--light);
}

button.google-btn:hover .g1 {
	color: #4285F4;
}

button.google-btn:hover .g2 {
	color: #DB4437;
}

button.google-btn:hover .g3 {
	color: #F4B400;
}

button.google-btn:hover .g4 {
	color: #0F9D58;
}

button.ai-summary-btn {
	border: 1px solid #cfd8e3;
	background: transparent;
	min-width: 36px;
	width: 36px;
	height: 36px;
	padding: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	flex-shrink: 0;
	line-height: 1;
}

button.ai-summary-btn img {
	display: block;
	width: 18px;
	height: 18px;
}

button.ai-summary-btn:hover {
	border-color: #4A90E2;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

button.delete-btn {
	background: var(--danger);
	color: white;
	min-width: 60px;
}

button.delete-btn:hover {
	background: #C9302C;
}

button.file-edit-btn {
	background: #6C757D;
	color: white;
	min-width: 60px;
}

button.file-edit-btn:hover {
	background: #5A6268;
}

button.rec-edit-btn {
	background: #6C757D;
	color: white;
	min-width: 60px;
}

button.rec-edit-btn:hover {
	background: #5A6268;
}

button#delete-all-btn,
button#delete-all-recs-btn {
	background: var(--danger);
	color: white;
	padding: 0.75rem 1.5rem;
	font-size: 1rem;
}

button#delete-all-btn:hover,
button#delete-all-recs-btn:hover {
	background: #C9302C;
}

#delete-all-wrap,
#delete-all-recs-wrap {
	text-align: center;
	margin: 16px 0 0 0;
}


#files-section {
	margin: 0 auto 3rem auto;
}

/* Desktop Table View */
#table-wrap,
.recommendations-wrap > div {
	margin: 0 auto;
	max-width: 1000px;
	width: 100%;
}

.file-table,
.rec-table {
	background: white;
	border-radius: 12px;
	box-shadow: var(--shadow);
	overflow: hidden;
	display: table;
	width: 100%;
	max-width: 100%;
	border-collapse: collapse;
	margin: 0 auto;
}

tbody tr {
	border-bottom: 1px solid var(--border);
	transition: background 0.2s;
}

tbody tr:hover {
	background: var(--light);
}

tbody tr:last-child {
	border-bottom: none;
}

.file-table td,
.rec-table td {
	padding: 0.85rem 0.35rem;
	vertical-align: middle;
}

.file-table td:first-child,
.rec-table td:first-child {
	width: 100%;
	text-align: left;
	font-weight: 500;
	color: var(--dark);
	font-size: 1.3rem;
	padding-left: 1.25rem;
	padding-right: 1.5rem;
}

.file-table td:not(:first-child),
.rec-table td:not(:first-child) {
	width: 1%;
	white-space: nowrap;
	text-align: right;
}

.file-table td:last-child,
.rec-table td:last-child {
	padding-right: 1.25rem;
}

/* Hide empty button cells so spacing between visible buttons remains uniform */
.file-table td:not(:first-child):empty,
.rec-table td:not(:first-child):empty {
	display: none;
}

/* Spacing for multiple buttons inside the same td */
.file-table td:not(:first-child) > button + button,
.file-table td:not(:first-child) > a + button,
.rec-table td:not(:first-child) > button + button {
	margin-left: 0.7rem;
}

.rating {
	/* background: #FFF3CD; */
	color: #856404;
	padding: 0.25rem 0.5rem;
	border-radius: 4px;
	font-size: 0.85rem;
	font-weight: 600;
}


.size {
	color: #888;
	font-size: 0.85rem;
	padding: 0.25rem;
	font-weight: normal;
}

.file-note {
	font-size: 1.05rem;
	font-weight: 400;
	color: #495057;
	display: inline-block;
	margin-top: 0.25rem;
	line-height: 1.35;
}

.file-note .file-note-icon,
.file-note i {
	margin-right: 0.35rem;
	color: #6c757d;
	font-size: 0.95em;
}

.file-note a {
	color: var(--primary);
	text-decoration: underline;
}

.file-note a:hover {
	color: var(--primary-dark);
}


/* Notes Section */
.notes-section {
	margin: 3rem auto;
	max-width: 800px;
	min-width: 680px;
}

.notes-section h2 {
	text-align: center;
	margin-bottom: 1.5rem;
}

.notes-wrap {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	justify-content: center;
}

.note-item {
	background: white;
	border-left: 4px solid var(--warning);
	border-radius: 8px;
	box-shadow: var(--shadow);
	padding: 1rem 1.2rem 1rem 1rem;
	position: relative;
	width: fit-content;
	transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.note-item.admin-draggable {
	cursor: grab;
	user-select: none;
}

.note-item.admin-draggable:active,
.note-item.dragging {
	cursor: grabbing;
	opacity: 0.55;
	box-shadow: var(--shadow-lg);
	transform: scale(0.98);
}


.note-item p {
	margin: 0;
	color: var(--dark);
	font-size: 1.1em;
}

.note-dismiss {
	position: absolute;
	top: 0.25rem;
	right: 0.25rem;
	background: transparent;
	border: none;
	font-size: 12px;
	color: #999;
	cursor: pointer;
	width: 20px;
	height: 20px;
	padding: 0;
	min-width: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: color 0.2s;
}

.note-dismiss:focus {
	outline: none;
}

.note-dismiss:hover {
	color: var(--dark);
	box-shadow: none;
	transform: none;
}

#show_all_notes_wrap {
	text-align: center;
	margin-top: 1rem;
}

#show_all_notes_link {
	color: var(--primary);
	text-decoration: none;
}

#show_all_notes_link:hover {
	text-decoration: underline;
}

/* Recommendations Section */
.recommendations-wrap {
	margin: 3rem auto;
	max-width: 1000px;
	text-align: center;
}

.recommendations-wrap h2 {
	margin-bottom: 1.5rem;
}




.vote-btn {
	background: var(--light);
	color: var(--dark);
	border: 1px solid var(--border);
	min-width: 60px;
}

.vote-btn.vote-up:hover {
	background: #e9ecef;
	/* light grey for inactive hover */
}

.vote-btn.vote-up.active {
	background: var(--success);
	color: white;
	border-color: var(--success);
}

.vote-btn.vote-up.active:hover {
	background: #4cae4c;
	/* darker green for active hover */
}

.vote-btn.vote-down:hover,
.vote-btn.vote-down.active {
	background: var(--danger);
	color: white;
	border-color: var(--danger);
}


/* Admin Forms */
.admin-note-form,
.admin-rec-form {
	max-width: 700px;
	margin: 2rem auto;
}

/* Modal Improvements */
.modal-content {
	border-radius: 12px;
	border: none;
	box-shadow: var(--shadow-lg);
}

.modal-header {
	background: var(--light);
	border-bottom: 1px solid var(--border);
	border-radius: 12px 12px 0 0;
}

/* AI Summary markdown body */
#aiSummaryModalBody {
	padding-top: 1rem;
}

.ai-summary-body {
	font-size: 1rem;
	line-height: 1.6;
}

.ai-summary-body> :first-child {
	margin-top: 0;
}

.ai-summary-body h1,
.ai-summary-body h2,
.ai-summary-body h3 {
	font-size: 1.1rem;
	font-weight: 600;
	margin: 1rem 0 0.4rem;
}

.ai-summary-body p {
	margin: 0 0 0.75rem;
}

.ai-summary-body ul,
.ai-summary-body ol {
	padding-left: 1.4rem;
	margin: 0 0 0.75rem;
}

.ai-summary-body strong {
	font-weight: 600;
}

/* Expanded folder drawer styling & contrast */
.folder-contents-row:hover {
	background: rgba(0, 0, 0, 0.25) !important;
}

.folder-files-box table tbody tr {
	transition: background 0.15s ease;
}

.folder-files-box table tbody tr:hover {
	background: rgba(255, 255, 255, 0.1) !important;
}

.folder-files-box table tbody tr:hover .size {
	color: rgba(255, 255, 255, 0.65) !important;
}

.folder-files-box a:hover {
	color: #ffffff !important;
	text-decoration: underline !important;
}

button.subfile-delete-btn {
	background: var(--danger);
	color: white;
	min-width: 38px;
	height: 32px;
	padding: 0;
}

button.subfile-delete-btn:hover {
	background: #C9302C;
}