/* Google Play Store Clone - Pixel Perfect Styles */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-green: #01875f;
  --primary-blue: #4285f4;
  --text-primary: #202124;
  --text-secondary: #5f6368;
  --text-tertiary: #80868b;
  --border-color: #dadce0;
  --bg-white: #ffffff;
  --link-color: #1a73e8;
  --star-color: #ffc107;
  --bar-color: #01875f;
  --rating-bar-bg: #e8eaed;
}

body {
  font-family:
    "Roboto",
    "Google Sans",
    -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  background-color: var(--bg-white);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.play-store-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 24px 24px 40px;
}

/* App Header */
.app-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
  position: relative;
}

.app-icon {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  overflow: hidden;
  flex-shrink: 0;
  background: #1e265c;
  display: flex;
  align-items: center;
  justify-content: center;
}

.app-icon img {
  width: 35.9px;
  height: 53.6px;
  object-fit: contain;
}

.app-icon .icon-text {
  font-size: 32px;
  display: none;
}

.app-icon.placeholder-icon .icon-text {
  display: block;
}

.app-info {
  flex: 1;
  padding-top: 4px;
}

.app-name {
  font-family: "Google Sans", "Roboto", sans-serif;
  font-size: 22px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 2px;
  letter-spacing: 0;
}

.developer-name {
  font-size: 14px;
  color: var(--link-color);
  text-decoration: none;
  font-weight: 500;
}

.developer-name:hover {
  text-decoration: underline;
}

.more-options {
  position: absolute;
  top: 0;
  right: 0;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  color: var(--text-secondary);
}

.more-options:hover {
  background-color: rgba(0, 0, 0, 0.04);
}

/* App Stats */
.app-stats {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  padding: 16px 0;
  margin-bottom: 8px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 24px;
  min-width: 80px;
}

.stat-item:first-child {
  padding-left: 0;
}

.stat-value {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 2px;
  height: 24px;
}

.stat-value .star {
  font-size: 12px;
  color: var(--text-primary);
}

.stat-value .stat-icon {
  font-size: 20px;
  color: var(--text-secondary);
}

.rated-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--text-secondary);
  border-radius: 3px;
  padding: 2px 4px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
}

.stat-label {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 4px;
  white-space: nowrap;
}

.stat-divider {
  width: 1px;
  height: 24px;
  background-color: var(--border-color);
}

/* Update Button */
.update-btn {
  width: 100%;
  padding: 10px 24px;
  background-color: var(--primary-green);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  margin-bottom: 24px;
  font-family: "Google Sans", "Roboto", sans-serif;
  letter-spacing: 0.25px;
}

.update-btn:hover {
  background-color: #017a55;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* Screenshots Section */
.screenshots-section {
  margin-bottom: 32px;
  margin-left: -24px;
  margin-right: -24px;
  padding: 0 24px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.screenshots-section::-webkit-scrollbar {
  display: none;
}

.screenshots-container {
  display: flex;
  gap: 12px;
  padding: 8px 0;
}

/* Outer container: 138x281 with purple background */
.screenshot-item {
  flex-shrink: 0;
  width: 138px;
  height: 281px;
  min-width: 138px;
  min-height: 281px;
  border-radius: 12px;
  overflow: hidden;
  background: #3d4476;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* iPhone frame: 103x221 */
.screenshot-item img {
  width: 103px;
  height: 221px;
  object-fit: contain;
  border-radius: 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

/* Logo Overlays for Screenshots */
.screenshot-logo-overlay {
  position: absolute;
  background-image: url('app-icon.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  z-index: 10;
  pointer-events: none;
}

.overlay-buy-hen {
  width: 32px;
  height: 48px;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.screenshot-placeholder {
  display: none;
  width: 100%;
  height: 100%;
  padding: 8px;
}

.screenshot-item.placeholder img {
  display: none;
}

.screenshot-item.placeholder .screenshot-placeholder {
  display: block;
}

.phone-mock {
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, #1a237e 0%, #283593 100%);
  border-radius: 8px;
  padding: 6px;
  display: flex;
  flex-direction: column;
}

.phone-header {
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  margin-bottom: 8px;
}

.phone-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.mock-logo {
  font-size: 24px;
}

.mock-text {
  font-size: 8px;
  color: rgba(255, 255, 255, 0.8);
  text-align: center;
}

.mock-card {
  width: 80%;
  height: 30px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 6px;
}

.mock-card.lg {
  height: 60px;
}

.mock-list {
  width: 80%;
  height: 16px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.mock-avatar {
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
}

.mock-text-sm {
  width: 50%;
  height: 8px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 2px;
}

.mock-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  width: 80%;
}

.mock-grid > div {
  height: 30px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.mock-chart {
  width: 60px;
  height: 60px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
}

.mock-promo {
  font-size: 14px;
  color: #4caf50;
  font-weight: 700;
}

/* Section Styles */
.section {
  padding: 20px 0;
  border-top: 1px solid var(--border-color);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.section-header h2 {
  font-family: "Google Sans", "Roboto", sans-serif;
  font-size: 16px;
  font-weight: 500;
  color: var(--text-primary);
}

.arrow-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.arrow-btn:hover {
  background-color: rgba(0, 0, 0, 0.04);
}

/* About Section */
.about-description {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.6;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-block;
  padding: 6px 12px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 12px;
  color: var(--text-secondary);
  background: transparent;
}

/* Data Safety Section */
.safety-description {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 20px;
}

.safety-items {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 16px;
}

.safety-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.safety-icon {
  font-size: 20px;
  color: var(--text-secondary);
  flex-shrink: 0;
  margin-top: 2px;
}

.safety-content {
  flex: 1;
}

.safety-title {
  font-size: 14px;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.safety-subtitle {
  font-size: 12px;
  color: var(--text-tertiary);
}

.see-details-link {
  color: var(--link-color);
  font-size: 14px;
  text-decoration: none;
  font-weight: 500;
}

.see-details-link:hover {
  text-decoration: underline;
}

/* Ratings Section */
.ratings-info {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.ratings-overview {
  display: flex;
  gap: 32px;
  margin-bottom: 32px;
}

.rating-score {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.big-rating {
  font-family: "Google Sans", "Roboto", sans-serif;
  font-size: 48px;
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 4px;
}

.stars-row {
  display: flex;
  gap: 2px;
  margin-bottom: 4px;
}

.stars-row .star {
  font-size: 12px;
  color: var(--border-color);
}

.stars-row .star.filled {
  color: var(--star-color);
}

.stars-row .star.half {
  color: var(--star-color);
}

.review-count {
  font-size: 12px;
  color: var(--text-secondary);
}

.rating-bars {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 400px;
  padding-top: 8px;
}

.bar-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bar-label {
  font-size: 12px;
  color: var(--text-secondary);
  width: 12px;
  text-align: right;
}

.bar-track {
  flex: 1;
  height: 10px;
  background-color: var(--rating-bar-bg);
  border-radius: 5px;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  background-color: var(--bar-color);
  border-radius: 5px;
}

/* Reviews List */
.reviews-list {
  display: flex;
  flex-direction: column;
}

.review-item {
  padding: 16px 0;
}

.review-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 8px;
}

.reviewer-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 14px;
  font-weight: 500;
  flex-shrink: 0;
}

.reviewer-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.reviewer-name {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-primary);
}

.review-date {
  font-size: 12px;
  color: var(--text-tertiary);
}

.review-stars {
  display: flex;
  gap: 1px;
  margin-bottom: 8px;
}

.review-stars .star {
  font-size: 12px;
  color: var(--border-color);
}

.review-stars .star.filled {
  color: var(--star-color);
}

.review-text {
  font-size: 14px;
  color: var(--text-primary);
  line-height: 1.5;
  margin-bottom: 8px;
}

.review-helpful {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-bottom: 12px;
}

.review-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.helpful-question {
  font-size: 12px;
  color: var(--text-secondary);
}

.helpful-buttons {
  display: flex;
  gap: 8px;
}

.helpful-btn {
  padding: 6px 16px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: transparent;
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
  font-family: "Roboto", sans-serif;
}

.helpful-btn:hover {
  background-color: rgba(0, 0, 0, 0.04);
}

/* Responsive */
@media (max-width: 600px) {
  .play-store-container {
    padding: 16px;
  }

  .app-stats {
    overflow-x: auto;
    scrollbar-width: none;
  }

  .stat-item {
    padding: 0 16px;
  }

  .ratings-overview {
    flex-direction: column;
    gap: 20px;
  }

  .rating-bars {
    max-width: 100%;
  }
}
