/**
 * TravelSocial Hybrid - osnovni frontend stilovi.
 * Namjerno minimalni i lako nadjačivi iz teme (niska specifičnost, BEM-ish klase).
 */

.tsh-auth-wrap,
.tsh-submit-wrap,
.tsh-wall,
.tsh-location-wrap {
	max-width: 640px;
	margin: 0 auto;
	font-family: inherit;
	box-sizing: border-box;
}

.tsh-location-wrap {
	max-width: 900px;
}

.tsh-auth-wrap *,
.tsh-submit-wrap *,
.tsh-wall *,
.tsh-location-wrap * {
	box-sizing: border-box;
}

/* Notices */
.tsh-notice {
	padding: 10px 14px;
	border-radius: 6px;
	margin-bottom: 16px;
	font-size: 14px;
}
.tsh-notice-success { background: #e6f6ea; color: #1e7e34; border: 1px solid #b6e3c1; }
.tsh-notice-error { background: #fdecea; color: #c0392b; border: 1px solid #f5c2be; }
.tsh-notice-info { background: #eaf2fb; color: #2a5db0; border: 1px solid #c3d9f5; }

/* Auth tabs */
.tsh-auth-tabs {
	display: flex;
	gap: 8px;
	margin-bottom: 20px;
	border-bottom: 1px solid #e2e2e2;
}
.tsh-tab-btn {
	background: none;
	border: none;
	padding: 10px 16px;
	font-size: 15px;
	cursor: pointer;
	border-bottom: 2px solid transparent;
	color: #666;
}
.tsh-tab-btn.is-active {
	color: #1a1a1a;
	border-bottom-color: #2271b1;
	font-weight: 600;
}
.tsh-tab-panel { display: none; }
.tsh-tab-panel.is-active { display: block; }

/* Forms */
.tsh-form .tsh-field {
	margin-bottom: 16px;
}
.tsh-form label {
	display: block;
	margin-bottom: 6px;
	font-weight: 600;
	font-size: 14px;
}
.tsh-form input[type="text"],
.tsh-form input[type="email"],
.tsh-form input[type="password"],
.tsh-form input[type="file"],
.tsh-form textarea {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid #d5d5d5;
	border-radius: 6px;
	font-size: 14px;
}
.tsh-field-checkbox label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-weight: 400;
}

.tsh-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 20px;
	border-radius: 6px;
	border: none;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: opacity 0.15s ease;
}
.tsh-btn-primary { background: #2271b1; color: #fff; }
.tsh-btn-secondary { background: #f0f0f1; color: #1a1a1a; }
.tsh-btn:hover { opacity: 0.9; }
.tsh-btn.is-loading { opacity: 0.6; cursor: wait; }
.tsh-btn:disabled { cursor: not-allowed; }

/* Photo preview */
.tsh-photo-preview {
	display: block;
	margin-top: 10px;
}
.tsh-photo-preview img {
	max-width: 100%;
	max-height: 220px;
	border-radius: 8px;
	object-fit: cover;
}

/* Star rating (interactive) */
.tsh-star-rating {
	display: inline-flex;
	gap: 4px;
	font-size: 28px;
	cursor: pointer;
	line-height: 1;
}
.tsh-star-rating .tsh-star {
	color: #d5d5d5;
	transition: color 0.1s ease;
}
.tsh-star-rating .tsh-star.is-filled,
.tsh-star-rating .tsh-star.is-hover {
	color: #f5a623;
}

/* Star rating (read-only, wall/location) */
.tsh-stars-readonly {
	display: inline-flex;
	gap: 2px;
	font-size: 16px;
	line-height: 1;
}
.tsh-stars-readonly .tsh-star { color: #d5d5d5; }
.tsh-stars-readonly .tsh-star.is-filled { color: #f5a623; }

/* Autocomplete */
.tsh-field-autocomplete { position: relative; }
.tsh-autocomplete { position: relative; display: block; }
.tsh-autocomplete-results {
	position: absolute;
	z-index: 20;
	top: 100%;
	left: 0;
	right: 0;
	background: #fff;
	border: 1px solid #d5d5d5;
	border-radius: 6px;
	max-height: 220px;
	overflow-y: auto;
	box-shadow: 0 4px 12px rgba(0,0,0,0.08);
	margin-top: 4px;
}
.tsh-autocomplete-option {
	padding: 8px 12px;
	font-size: 14px;
	cursor: pointer;
}
.tsh-autocomplete-option:hover,
.tsh-autocomplete-option:focus {
	background: #f0f6fc;
	outline: none;
}
.tsh-autocomplete-empty {
	padding: 8px 12px;
	font-size: 13px;
	color: #888;
}

/* Wall grid */
.tsh-wall-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 20px;
	margin-bottom: 24px;
}
.tsh-wall-card {
	border: 1px solid #e5e5e5;
	border-radius: 10px;
	overflow: hidden;
	background: #fff;
	display: flex;
	flex-direction: column;
}
.tsh-wall-card-header {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 14px;
}
.tsh-avatar img { border-radius: 50%; display: block; }
.tsh-author-meta { display: flex; flex-direction: column; font-size: 13px; }
.tsh-author-meta time { color: #888; font-size: 12px; }
.tsh-wall-card-photo img {
	width: 100%;
	height: 200px;
	object-fit: cover;
	display: block;
}
.tsh-wall-card-body { padding: 12px 14px 16px; }
.tsh-wall-card-text { font-size: 14px; margin: 10px 0; color: #333; }
.tsh-wall-card-location {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-size: 13px;
	color: #2271b1;
	text-decoration: none;
}
.tsh-wall-card-location:hover { text-decoration: underline; }

.tsh-wall-load-more-wrap {
	display: flex;
	justify-content: center;
}

.tsh-empty {
	text-align: center;
	color: #888;
	padding: 40px 0;
}

/* Location page */
.tsh-location-header { margin-bottom: 20px; }
.tsh-location-photo-wrap img {
	width: 100%;
	max-height: 380px;
	object-fit: cover;
	border-radius: 10px;
	margin-bottom: 16px;
}
.tsh-location-title { margin: 0 0 8px; font-size: 28px; }
.tsh-location-address { color: #666; margin: 0 0 10px; }
.tsh-location-rating {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 10px;
}
.tsh-rating-summary { font-size: 14px; color: #555; }
.tsh-location-coords { font-size: 12px; color: #999; }
.tsh-location-wall { margin-top: 32px; }
.tsh-location-wall h2 { font-size: 20px; margin-bottom: 16px; }
