/* ArenaMobiles homepage discovery styles
   Cleaned and consolidated: 2026-09-25 */

.home-phone-finder {
    margin-bottom: 24px;
    padding: 24px;
    background: #ffffff;
    border: 1px solid #e7ebf0;
    border-top: 5px solid #719cc8;
    border-radius: 4px;
    box-shadow: 0 4px 18px rgba(30, 55, 90, 0.07);
    direction: ltr;
}

.home-finder-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.home-finder-heading h2 {
    margin: 0 0 6px;
    color: #333333;
    font-size: 28px;
    font-weight: 600;
}

.home-finder-heading p {
    margin: 0;
    color: #777777;
    font-size: 15px;
}

.home-finder-advanced-link {
    color: #6f42ff;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.home-finder-advanced-link:hover,
.home-finder-advanced-link:focus {
    color: #5430d6;
    text-decoration: none;
}

.home-finder-field {
    min-width: 0;
}

.home-finder-field label {
    display: block;
    margin-bottom: 7px;
    color: #444444;
    font-size: 14px;
    font-weight: 600;
}

.home-finder-field .form-control {
    height: 44px;
    border-color: #d9dee6;
    border-radius: 4px;
    box-shadow: none;
}

.home-finder-field .form-control:focus {
    border-color: #6f42ff;
    box-shadow: 0 0 0 2px rgba(111, 66, 255, 0.14);
}

.home-finder-action .btn {
    width: 100%;
    height: 44px;
    padding-right: 20px;
    padding-left: 20px;
    border: 0;
    border-radius: 4px;
    background: #719cc8;
    font-size: 15px;
    font-weight: 600;
}

.home-finder-action .btn:hover,
.home-finder-action .btn:focus {
    background: #5f8bb8;
}

.home-finder-action .fa {
    margin-right: 6px;
}

/* Main two-column discovery section */
.home-discovery-grid {
	display: grid;
	grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
	gap: 22px;
	align-items: stretch;
	margin-bottom: 30px;
}

/* Both panels */
.home-phone-finder,
.home-phone-categories {
	background: #fff;
	border: 1px solid #ececf2;
	border-radius: 12px;
	padding: 28px;
	box-shadow: 0 4px 18px rgba(30, 43, 70, 0.05);
}

/* Prevent the old finder margin from affecting the grid */
.home-discovery-grid .home-phone-finder {
	margin: 0;
}

@media (max-width: 1100px) {
    .home-discovery-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767px) {
    .home-discovery-grid {
        gap: 16px;
    }

    .home-phone-finder {
        padding: 20px 16px;
        border-radius: 9px;
    }
}

/* Price values */
.home-price-values {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
	gap: 10px;
	align-items: center;
}

.home-price-value {
	height: 44px;
	display: flex;
	align-items: center;
	gap: 7px;
	padding: 0 15px;
	background: #fff;
	border: 1px solid #d9dde7;
	border-radius: 7px;
	color: #555;
}

.home-price-value span {
	font-weight: 700;
	color: #333;
}

.home-price-value strong {
	font-size: 16px;
	font-weight: 500;
}

.home-price-to {
	font-weight: 600;
	color: #555;
	text-align: center;
}

/* Dual slider */
.home-price-slider {
	position: relative;
	height: 28px;
	margin-top: 15px;
}

.home-price-slider-track,
#home-price-slider-range {
	position: absolute;
	top: 11px;
	left: 0;
	width: 100%;
	height: 5px;
	border-radius: 20px;
}

.home-price-slider-track {
	background: #dfe2e8;
}

#home-price-slider-range {
	background: #6f42ff;
}

.home-price-slider input[type="range"] {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 28px;
	margin: 0;
	padding: 0;
	background: transparent;
	pointer-events: none;
	-webkit-appearance: none;
	appearance: none;
}

/* Chrome, Edge and Safari handles */
.home-price-slider input[type="range"]::-webkit-slider-thumb {
	width: 21px;
	height: 21px;
	border: 3px solid #6f42ff;
	border-radius: 50%;
	background: #fff;
	cursor: pointer;
	pointer-events: auto;
	box-shadow: 0 2px 7px rgba(111, 66, 255, 0.28);
	-webkit-appearance: none;
	appearance: none;
}

/* Firefox handles */
.home-price-slider input[type="range"]::-moz-range-thumb {
	width: 17px;
	height: 17px;
	border: 3px solid #6f42ff;
	border-radius: 50%;
	background: #fff;
	cursor: pointer;
	pointer-events: auto;
	box-shadow: 0 2px 7px rgba(111, 66, 255, 0.28);
}

.home-price-slider input[type="range"]::-moz-range-track {
	background: transparent;
	border: none;
}

#home-min-price-range {
	z-index: 3;
}

#home-max-price-range {
	z-index: 4;
}

/* Mobile */
@media (max-width: 767px) {
	.home-price-value {
		padding: 0 10px;
	}

	.home-price-value strong {
		font-size: 14px;
	}
}

/* Shaded finder box */
.home-finder-search-box {
	padding: 24px;
	background: #f4f5f8;
	border-radius: 11px;
}

.home-finder-search-box .home-finder-field {
	min-width: 0;
}

.home-finder-search-box .home-finder-action {
	grid-column: 1 / -1;
	margin: 0;
}

.home-finder-search-box .home-finder-action .btn {
	width: 100%;
	height: 54px;
	border: 0;
	border-radius: 7px;
	background: #375d81;
	color: #fff;
	font-size: 18px;
	font-weight: 700;
	text-shadow: none;
	box-shadow: none;
}

.home-finder-search-box .home-finder-action .btn:hover {
	background: #6f42ff;
}

/* Popular devices this week */
.home-weekly-devices {
	min-width: 0;
}

.home-weekly-heading {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 15px;
	margin-bottom: 12px;
}

.home-weekly-heading h3 {
	margin: 0 0 5px;
	font-size: 20px;
	font-weight: 700;
	color: #333;
}

.home-weekly-heading p {
	margin: 0;
	font-size: 13px;
	color: #888;
}

.home-weekly-icon {
	width: 39px;
	height: 39px;
	flex: 0 0 39px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 9px;
	background: #eee9ff;
	color: #6f42ff;
	font-size: 16px;
}

/* Device rows */
.home-weekly-device {
	min-height: 68px;
	display: grid;
	grid-template-columns: 25px 50px minmax(0, 1fr) auto;
	align-items: center;
	gap: 10px;
	padding: 9px 3px;
	border-bottom: 1px solid #e5e7ed;
	color: #333;
	text-decoration: none;
	transition:
		color 0.2s ease,
		background-color 0.2s ease,
		padding 0.2s ease;
}

.home-weekly-device:last-child {
	border-bottom: 0;
}

.home-weekly-device:hover {
	padding-left: 7px;
	color: #6f42ff;
	background: #faf9ff;
	text-decoration: none;
}

/* Ranking number */
.home-weekly-rank {
	font-size: 13px;
	font-weight: 700;
	color: #999;
	text-align: center;
}

.home-weekly-device:nth-child(1) .home-weekly-rank {
	color: #e5a100;
}

.home-weekly-device:nth-child(2) .home-weekly-rank {
	color: #89919a;
}

.home-weekly-device:nth-child(3) .home-weekly-rank {
	color: #b56d3c;
}

/* Device image */
.home-weekly-image {
	width: 48px;
	height: 48px;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	border: 1px solid #ececf1;
	border-radius: 8px;
	background: #fff;
}

.home-weekly-image img {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

/* Device name */
.home-weekly-name {
	min-width: 0;
	display: flex;
	flex-direction: column;
	line-height: 1.25;
}

.home-weekly-name small {
	margin-bottom: 3px;
	color: #888;
	font-size: 12px;
}

.home-weekly-name strong {
	overflow: hidden;
	color: inherit;
	font-size: 14px;
	font-weight: 600;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* Weekly view count */
.home-weekly-views {
	display: flex;
	align-items: center;
	gap: 5px;
	padding: 6px 8px;
	border-radius: 20px;
	background: #f1edff;
	color: #6f42ff;
	font-size: 12px;
	font-weight: 700;
	white-space: nowrap;
}

.home-weekly-views i {
	font-size: 12px;
}

/* Empty weekly list */
.home-weekly-empty {
	padding: 35px 15px;
	border: 1px dashed #d9dce5;
	border-radius: 9px;
	color: #999;
	text-align: center;
}

.home-weekly-empty i {
	margin-bottom: 8px;
	font-size: 25px;
}

.home-weekly-empty p {
	margin: 0;
	font-size: 14px;
}

/* Mobile */
@media (max-width: 600px) {
	.home-weekly-device {
		grid-template-columns: 22px 46px minmax(0, 1fr) auto;
	}

	.home-weekly-image {
		width: 44px;
		height: 44px;
	}
}
.home-top-rated {
    padding: 30px;
    border: 1px solid #e7e8ef;
    border-radius: 18px;
    background: #fff;
    min-width: 0;
}

/* =========================================================
   HOME FINDER: horizontal controls + weekly devices below
   ========================================================= */

/* The PHP already places the finder before the weekly list. */
.home-finder-inner-grid {
	display: block;
	margin-top: 24px;
}

/* Brand, Category and Price Range on one desktop row. */

.home-finder-inner-grid .home-weekly-devices {
	margin-top: 26px;
	padding-top: 24px;
	border-top: 1px solid #e4e7ee;
}

.home-weekly-heading {
	margin-bottom: 16px;
}

.home-weekly-list {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
}

.home-weekly-device,
.home-weekly-device:last-child {
	min-height: 82px;
	padding: 10px 12px;
	border: 1px solid #e5e7ed;
	border-radius: 10px;
	background: #ffffff;
}

.home-weekly-device:hover {
	padding-left: 12px;
	border-color: #6f42ff;
	box-shadow: 0 4px 14px rgba(111, 66, 255, 0.09);
}

.home-weekly-empty {
	grid-column: 1 / -1;
}

/* Medium screens: Brand and Category share row one; Price uses row two. */
@media (max-width: 991px) {
	.home-finder-search-box .home-finder-form {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.home-finder-search-box .home-price-field,
	.home-finder-search-box .home-finder-action {
		grid-column: 1 / -1;
	}
}

/* Phones: stack the controls and device cards. */
@media (max-width: 600px) {
	.home-finder-search-box .home-finder-form,
	.home-weekly-list {
		grid-template-columns: 1fr;
	}

	.home-finder-search-box .home-price-field,
	.home-finder-search-box .home-finder-action {
		grid-column: auto;
	}
}

.top-rated-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.top-rated-header h2 {
    margin: 0 0 6px;
    color: #25232d;
    font-size: 28px;
    font-weight: 700;
    line-height: 1.1;
}

.top-rated-header p {
    margin: 0;
    color: #77727e;
    font-size: 15px;
}

.top-rated-header-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 56px;
    width: 56px;
    height: 56px;
    border-radius: 15px;
    color: #7047ff;
    background: #f0eaff;
    font-size: 23px;
}

.top-rated-list {
    display: flex;
    flex-direction: column;
}

.top-rated-device {
    display: grid;
    grid-template-columns: 28px 58px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid #e6e7ed;
    color: inherit;
    text-decoration: none;
}

.top-rated-device:last-child {
    border-bottom: 0;
}

.top-rated-device:hover,
.top-rated-device:focus {
    color: inherit;
    text-decoration: none;
    background: #faf9ff;
}

.top-rated-rank {
    color: #a6a2aa;
    font-size: 17px;
    font-weight: 700;
    text-align: center;
}

.top-rated-device:nth-child(1) .top-rated-rank {
    color: #f3a000;
}

.top-rated-device:nth-child(2) .top-rated-rank {
    color: #84909c;
}

.top-rated-device:nth-child(3) .top-rated-rank {
    color: #b87333;
}

.top-rated-image {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    overflow: hidden;
    border: 1px solid #e7e8ef;
    border-radius: 10px;
    background: #fff;
}

.top-rated-image img {
    width: 100%;
    height: 100%;
    padding: 4px;
    object-fit: contain;
}

.top-rated-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.top-rated-info span {
    margin-bottom: 2px;
    color: #88838d;
    font-size: 13px;
}

.top-rated-info strong {
    overflow: hidden;
    color: #24212a;
    font-size: 16px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.top-rated-info small {
    margin-top: 3px;
    color: #99949e;
}

.top-rated-score {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-width: 76px;
    padding: 9px 10px;
    border-radius: 20px;
    font-size: 15px;
    font-weight: 700;
    white-space: nowrap;
}

.top-rated-score small {
    font-size: 11px;
    font-weight: 600;
}

.top-rated-score.rating-red {
    color: #d83b45;
    background: #ffe8ea;
}

.top-rated-score.rating-orange {
    color: #d77a00;
    background: #fff0d8;
}

.top-rated-score.rating-green {
    color: #178548;
    background: #e5f8ed;
}

.top-rated-score.rating-purple {
    color: #7047ff;
    background: #eee8ff;
}

.top-rated-empty {
    padding: 45px 20px;
    color: #8a8590;
    text-align: center;
}

.top-rated-empty i {
    display: block;
    margin-bottom: 12px;
    color: #7047ff;
    font-size: 36px;
}

.top-rated-empty strong {
    display: block;
    margin-bottom: 5px;
    color: #39343f;
    font-size: 17px;
}

.top-rated-empty p {
    margin: 0;
}

@media (max-width: 767px) {
    .home-top-rated {
        padding: 22px 18px;
    }

    .top-rated-header h2 {
        font-size: 23px;
    }

    .top-rated-device {
        grid-template-columns: 24px 50px minmax(0, 1fr) auto;
        gap: 9px;
    }

    .top-rated-image {
        width: 50px;
        height: 50px;
    }

    .top-rated-score {
        min-width: 67px;
        padding: 8px;
        font-size: 13px;
    }
}
/* ========================================
   Upcoming and Rumored Devices
   ======================================== */

.upcoming-devices {
    margin-top: 24px;
}

.upcoming-device-card {
    position: relative;
    overflow: hidden;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.upcoming-device-card:hover {
    transform: translateY(-3px);
    border-color: #6f42ff;
    box-shadow: 0 7px 20px rgba(38, 42, 70, 0.12);
}

/* Status badges */
.upcoming-status {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 5;
    padding: 5px 9px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.device-status-upcoming {
    color: #147849;
    background: #dff7e9;
    border: 1px solid #bcebd0;
}

.device-status-rumored {
    color: #7047ff;
    background: #eee8ff;
    border: 1px solid #dcd0ff;
}

/* Expected release date */
.upcoming-release-date {
    margin-top: 9px;
    color: #777;
    font-size: 12px;
    font-weight: 500;
}

.upcoming-release-date i {
    margin-right: 4px;
    color: #6f42ff;
}

/* Empty state */
.upcoming-empty {
    padding: 45px 20px;
    color: #888;
    text-align: center;
}

.upcoming-empty i {
    display: block;
    margin-bottom: 10px;
    color: #6f42ff;
    font-size: 30px;
}

.upcoming-empty p {
    margin: 0;
    font-size: 14px;
}
/* Popular Comparisons */
.popular-comparisons-section {
    margin: 28px 0;
    padding: 24px;
    background: #ffffff;
    border: 1px solid #e7eaf0;
    border-radius: 18px;
}

.popular-comparisons-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 22px;
}

.popular-comparisons-header h2 {
    margin: 0 0 5px;
    color: #263238;
    font-size: 28px;
    font-weight: 700;
}

.popular-comparisons-header p {
    margin: 0;
    color: #7a7f87;
    font-size: 15px;
}

.popular-comparisons-header > i {
    display: flex;
    width: 52px;
    height: 52px;
    align-items: center;
    justify-content: center;
    color: #6946ff;
    background: #eeeaff;
    border-radius: 14px;
    font-size: 23px;
}

.popular-comparisons-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.popular-comparison-card {
    display: block;
    overflow: hidden;
    color: #263238;
    background: #ffffff;
    border: 1px solid #e1e5ec;
    border-radius: 14px;
    text-decoration: none;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.popular-comparison-card:hover,
.popular-comparison-card:focus {
    color: #263238;
    border-color: #7450ff;
    box-shadow: 0 10px 25px rgba(75, 55, 160, 0.12);
    text-decoration: none;
    transform: translateY(-3px);
}

.comparison-devices {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 38px minmax(0, 1fr);
    align-items: center;
    padding: 18px 14px;
}

.comparison-device {
    min-width: 0;
    text-align: center;
}

.comparison-device img {
    display: block;
    width: 78px;
    height: 90px;
    margin: 0 auto 10px;
    object-fit: contain;
}

.comparison-device span {
    display: -webkit-box;
    min-height: 40px;
    overflow: hidden;
    color: #30343b;
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.comparison-vs {
    display: flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    color: #6946ff;
    background: #eeeaff;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 800;
}

.comparison-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 16px;
    color: #858a93;
    background: #f8f9fc;
    border-top: 1px solid #e7eaf0;
    font-size: 13px;
}

.comparison-card-footer span i {
    margin-right: 4px;
    color: #6946ff;
}

.comparison-card-footer strong {
    color: #6946ff;
    font-size: 13px;
}

.comparison-card-footer strong i {
    margin-left: 4px;
}

/* Tablet and mobile */
@media (max-width: 767px) {
    .popular-comparisons-section {
        padding: 18px 14px;
        border-radius: 14px;
    }

    .popular-comparisons-header h2 {
        font-size: 23px;
    }

    .popular-comparisons-grid {
        grid-template-columns: 1fr;
    }

    .comparison-device img {
        width: 72px;
        height: 82px;
    }
}
/* Sidebar Popular Comparisons */
.sidebar-comparisons {
    overflow: hidden;
    margin-top: 20px;
    border: 1px solid #e1e5ec;
    border-radius: 12px;
}

.sidebar-comparisons .panel-body {
    padding: 12px;
}

.sidebar-comparison-item {
    display: block;
    margin-bottom: 12px;
    overflow: hidden;
    color: #283746;
    background: #ffffff;
    border: 1px solid #e2e6ec;
    border-radius: 10px;
    text-decoration: none;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.sidebar-comparison-item:last-child {
    margin-bottom: 0;
}

.sidebar-comparison-item:hover,
.sidebar-comparison-item:focus {
    color: #283746;
    border-color: #6946ff;
    box-shadow: 0 6px 18px rgba(70, 52, 150, 0.12);
    text-decoration: none;
    transform: translateY(-2px);
}

.sidebar-comparison-phones {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr);
    align-items: center;
    padding: 12px 8px;
}

.sidebar-comparison-phone {
    min-width: 0;
    text-align: center;
}

.sidebar-comparison-phone img {
    display: block;
    width: 90px;
    height: 105px;
    max-width: 100%;
    margin: 0 auto 10px;
    object-fit: contain;
}

.sidebar-comparison-phone span {
    display: -webkit-box;
    min-height: 34px;
    overflow: hidden;
    color: #313943;
    font-size: 12px;
    font-weight: 700;
    line-height: 17px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.sidebar-comparison-phones > strong {
    display: flex;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    color: #6946ff;
    background: #eeeaff;
    border-radius: 50%;
    font-size: 11px;
}

.sidebar-comparison-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 11px;
    color: #7e8490;
    background: #f8f9fc;
    border-top: 1px solid #e5e8ed;
    font-size: 12px;
}

.sidebar-comparison-footer i {
    color: #6946ff;
}

.sidebar-comparison-footer span:last-child {
    color: #6946ff;
    font-weight: 700;
}

/* Sidebar becomes full width on smartphones */
@media (max-width: 767px) {
    .sidebar-comparisons {
        margin-top: 18px;
    }

    .sidebar-comparison-phone img {
		width: 85px;
		height: 100px;
}

    .sidebar-comparison-phone span {
        font-size: 13px;
    }
}

/* Grouped homepage finder layout */
.home-finder-search-box .home-finder-form {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 1.15fr);
    gap: 16px;
    align-items: stretch;
}

.home-filter-group {
    min-width: 0;
    padding: 18px;
    background: #ffffff;
    border: 1px solid #dfe4ea;
    border-radius: 10px;
    box-sizing: border-box;
}

.home-brand-category-group {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.home-price-group,
.home-price-group .home-price-field {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.home-finder-search-box .home-price-group .home-price-field {
    grid-column: auto;
}

.home-price-values {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        auto
        minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    width: 100%;
    min-width: 0;
}

.home-price-value {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    overflow: hidden;
    white-space: nowrap;
}

.home-price-slider {
    width: calc(100% - 20px);
    margin-right: 10px;
    margin-left: 10px;
}

.home-finder-search-box .home-finder-action {
    grid-column: 1 / -1;
}
@media (max-width: 767px) {
    .home-finder-search-box .home-finder-form {
        grid-template-columns: 1fr;
    }

    .home-brand-category-group {
        grid-template-columns: 1fr;
    }

    .home-filter-group {
        padding: 14px;
    }

    .home-finder-search-box .home-finder-action {
        grid-column: auto;
    }

    .home-price-values {
        gap: 7px;
    }

    .home-price-value {
        padding-right: 10px;
        padding-left: 10px;
    }
}
