/**
 * Food Comments - front-end styles.
 * All classes are prefixed with .fc- to avoid theme conflicts.
 */

.fc-wrap {
	--fc-accent: #D32F2F;
	--fc-accent-dark: #B71C1C;
	--fc-text: #1f2328;
	--fc-muted: #6b7280;
	--fc-border: #e6e8eb;
	--fc-radius: 14px;
	box-sizing: border-box;
	width: 100%;
	max-width: 820px;
	margin: 0 auto;
	color: var(--fc-text);
	font-size: 16px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

.fc-wrap *,
.fc-wrap *::before,
.fc-wrap *::after {
	box-sizing: border-box;
}

/* ------------------------------------------------------------------ */
/* Form                                                                */
/* ------------------------------------------------------------------ */

.fc-form-card {
	background: #fff;
	border: 1px solid var(--fc-border);
	border-radius: var(--fc-radius);
	padding: 26px;
	box-shadow: 0 2px 10px rgba(17, 24, 39, .06);
	margin: 0 0 28px;
}

.fc-form__title {
	margin: 0 0 6px;
	font-size: 1.35rem;
	line-height: 1.3;
	font-weight: 700;
	color: var(--fc-text);
}

.fc-form__subtitle {
	margin: 0 0 18px;
	color: var(--fc-muted);
	font-size: .92rem;
}

.fc-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 14px;
}

.fc-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
}

.fc-field--full {
	grid-column: 1 / -1;
}

.fc-label {
	font-size: .88rem;
	font-weight: 600;
	color: var(--fc-text);
}

.fc-req {
	color: var(--fc-accent);
}

.fc-input,
.fc-textarea {
	width: 100%;
	padding: 11px 13px;
	border: 1px solid var(--fc-border);
	border-radius: 10px;
	background: #fff;
	color: inherit;
	font: inherit;
	line-height: 1.5;
	transition: border-color .15s ease, box-shadow .15s ease;
}

.fc-input::placeholder,
.fc-textarea::placeholder {
	color: #9aa1ab;
}

.fc-input:focus,
.fc-textarea:focus {
	outline: none;
	border-color: var(--fc-accent);
	box-shadow: 0 0 0 3px rgba(211, 47, 47, .13);
}

.fc-textarea {
	min-height: 120px;
	resize: vertical;
}

.fc-input.is-error,
.fc-textarea.is-error {
	border-color: var(--fc-accent);
	background: #fff6f6;
}

.fc-error {
	display: none;
	color: var(--fc-accent);
	font-size: .8rem;
}

.fc-error.is-visible {
	display: block;
}

.fc-form__actions {
	margin-top: 18px;
}

.fc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 12px 26px;
	border: 1px solid transparent;
	border-radius: 10px;
	background: var(--fc-accent);
	color: #fff;
	font: inherit;
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	text-decoration: none;
	transition: background .16s ease, transform .1s ease, opacity .16s ease;
}

.fc-btn:hover,
.fc-btn:focus {
	background: var(--fc-accent-dark);
	color: #fff;
}

.fc-btn:active {
	transform: translateY(1px);
}

.fc-btn[disabled] {
	opacity: .65;
	cursor: not-allowed;
	transform: none;
}

.fc-btn--ghost {
	background: transparent;
	color: var(--fc-accent);
	border-color: var(--fc-accent);
}

.fc-btn--ghost:hover,
.fc-btn--ghost:focus {
	background: rgba(211, 47, 47, .07);
	color: var(--fc-accent-dark);
}

.fc-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.fc-alert {
	display: none;
	margin: 0 0 16px;
	padding: 11px 14px;
	border-radius: 10px;
	font-size: .9rem;
}

.fc-alert.is-visible {
	display: block;
}

.fc-alert--success {
	background: #edf7ed;
	border: 1px solid #c6e6c7;
	color: #1b5e20;
}

.fc-alert--error {
	background: #fdecea;
	border: 1px solid #f5c6c6;
	color: #b71c1c;
}

/* ------------------------------------------------------------------ */
/* Comment list                                                        */
/* ------------------------------------------------------------------ */

.fc-list-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px;
	margin: 0 0 14px;
	flex-wrap: wrap;
}

.fc-list-title {
	margin: 0;
	font-size: 1.2rem;
	font-weight: 700;
	color: var(--fc-text);
}

.fc-count {
	color: var(--fc-muted);
	font-size: .85rem;
}

.fc-list {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.fc-card {
	background: #fff;
	border: 1px solid var(--fc-border);
	border-radius: var(--fc-radius);
	padding: 18px 20px;
	box-shadow: 0 2px 8px rgba(17, 24, 39, .05);
	animation: fc-fade-in .35s ease both;
}

@keyframes fc-fade-in {
	from {
		opacity: 0;
		transform: translateY(8px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}

.fc-card__head {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 10px;
}

.fc-avatar {
	flex: 0 0 44px;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: var(--fc-accent);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.05rem;
	font-weight: 700;
	text-transform: uppercase;
	user-select: none;
}

.fc-card__meta {
	display: flex;
	flex-direction: column;
	line-height: 1.35;
	min-width: 0;
}

.fc-card__name {
	font-size: .98rem;
	font-weight: 700;
	word-break: break-word;
}

.fc-card__date {
	color: var(--fc-muted);
	font-size: .8rem;
}

.fc-card__body {
	font-size: .96rem;
	line-height: 1.65;
	overflow-wrap: anywhere;
}

.fc-card__body p {
	margin: 0 0 10px;
}

.fc-card__body p:last-child {
	margin-bottom: 0;
}

.fc-card__contact {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 18px;
	margin-top: 12px;
	padding-top: 12px;
	border-top: 1px dashed var(--fc-border);
	font-size: .85rem;
	color: var(--fc-muted);
}

.fc-card__contact a {
	color: var(--fc-accent);
	text-decoration: none;
}

.fc-card__contact a:hover {
	text-decoration: underline;
}

.fc-empty {
	background: #fff;
	border: 1px dashed var(--fc-border);
	border-radius: var(--fc-radius);
	padding: 34px 22px;
	text-align: center;
	color: var(--fc-muted);
}

.fc-more-wrap {
	display: flex;
	justify-content: center;
	margin-top: 20px;
}

.fc-spinner {
	width: 15px;
	height: 15px;
	border: 2px solid rgba(255, 255, 255, .45);
	border-top-color: #fff;
	border-radius: 50%;
	animation: fc-spin .7s linear infinite;
}

.fc-btn--ghost .fc-spinner {
	border-color: rgba(211, 47, 47, .35);
	border-top-color: var(--fc-accent);
}

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

/* ------------------------------------------------------------------ */
/* Mobile                                                              */
/* ------------------------------------------------------------------ */

@media (max-width: 600px) {

	.fc-grid {
		grid-template-columns: 1fr;
	}

	.fc-form-card {
		padding: 20px 16px;
	}

	.fc-card {
		padding: 16px;
	}

	.fc-btn {
		width: 100%;
	}
}
