/* =========================================
   Fake Email Generator - Glassmorphism Styles
========================================= */

.page-wrapper {
  width: 90%;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 6fr 1fr;
  gap: 2rem;
  padding: 60px 0 4rem 0;
  flex: 1;
}
.ad-space-left,
.ad-space-right {
  width: 100%;
  min-height: 600px;
  background: rgba(255, 255, 255, 0.4);
  border: 1px dashed var(--glass-border, rgba(255, 255, 255, 0.7));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted, #475569);
  font-size: 0.8rem;
}
.main-content {
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.glass-panel {
  background: var(--glass-bg, rgba(255, 255, 255, 0.55));
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.7));
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--glass-shadow, 0 8px 32px 0 rgba(0, 85, 255, 0.15));
}
.glass-card {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.7));
  border-radius: 8px;
  padding: 1.5rem;
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}

.background-shapes {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
}
.shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.6;
}
.shape-1 {
  width: 400px;
  height: 400px;
  background: #00a2ff;
  top: -100px;
  left: -100px;
}
.shape-2 {
  width: 500px;
  height: 500px;
  background: #0033cc;
  bottom: -150px;
  right: -100px;
}
.shape-3 {
  width: 300px;
  height: 300px;
  background: #7dd3fc;
  top: 40%;
  left: 30%;
}

h1 {
  margin-bottom: 0.5rem;
  color: var(--text-dark, #1e293b);
  font-size: 1.8rem;
}
h2 {
  font-size: 1.4rem;
  color: var(--text-dark, #1e293b);
  margin-bottom: 1.5rem;
  border-bottom: 2px solid var(--glass-border);
  padding-bottom: 0.5rem;
}

/* Generator Layout */
.generator-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

/* Controls Section */
.email-display-wrapper {
  margin-bottom: 1.5rem;
}
.email-display-wrapper label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.email-display {
  display: flex;
  gap: 0.5rem;
}
.password-output {
  flex: 1;
  padding: 1.25rem;
  font-size: 1.25rem;
  font-family: "Courier New", Courier, monospace;
  font-weight: 700;
  color: var(--text-dark);
  background: rgba(255, 255, 255, 0.9);
  border: 2px solid var(--glass-border);
  border-radius: 8px;
  outline: none;
  transition: border-color 0.2s;
}
.password-output:focus {
  border-color: var(--accent);
}

.icon-btn {
  background: var(--accent, #0055ff);
  color: white;
  border: none;
  border-radius: 8px;
  width: 60px;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    background 0.2s,
    transform 0.1s;
}
.icon-btn:hover {
  background: var(--accent-hover, #0033cc);
}
.icon-btn:active {
  transform: scale(0.95);
}

.action-buttons-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}
.generate-btn {
  background: var(--accent, #0055ff);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  height: 50px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
}
.generate-btn:hover:not(:disabled) {
  background: var(--accent-hover, #0033cc);
}
.generate-btn:active:not(:disabled) {
  transform: scale(0.98);
}
.generate-btn.outline-btn {
  background: transparent;
  border: 2px solid var(--accent);
  color: var(--accent);
}
.generate-btn.outline-btn:hover {
  background: rgba(0, 85, 255, 0.1);
}
.generate-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.auto-refresh-status {
  font-size: 0.85rem;
  color: #10b981;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Inbox Section */
.inbox-card {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  height: 500px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  position: relative;
}
.inbox-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.5);
}
.inbox-header h3 {
  font-size: 1.1rem;
  color: var(--text-dark);
  margin: 0;
}
.email-count {
  font-size: 0.85rem;
  background: #e2e8f0;
  color: #475569;
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-weight: 600;
}

.inbox-list {
  flex: 1;
  overflow-y: auto;
}
.inbox-list::-webkit-scrollbar {
  width: 6px;
}
.inbox-list::-webkit-scrollbar-track {
  background: transparent;
}
.inbox-list::-webkit-scrollbar-thumb {
  background: rgba(0, 85, 255, 0.3);
  border-radius: 4px;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--text-muted);
  text-align: center;
  padding: 2rem;
}
.empty-state i {
  font-size: 3rem;
  color: #cbd5e1;
  margin-bottom: 1rem;
}
.empty-state p {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dark);
  margin: 0;
}
.empty-state span {
  font-size: 0.9rem;
}

/* Email Item */
.email-item {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--glass-border);
  cursor: pointer;
  transition: background 0.2s;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.email-item:hover {
  background: rgba(0, 85, 255, 0.05);
}
.email-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.email-sender {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 70%;
}
.email-date {
  font-size: 0.8rem;
  color: var(--text-muted);
}
.email-subject {
  font-size: 0.9rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Email Reader */
.email-reader {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  z-index: 10;
}
.reader-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--glass-border);
  background: white;
}
.back-btn {
  background: transparent;
  border: none;
  color: var(--accent);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  padding: 0;
  margin-bottom: 1rem;
  font-size: 0.95rem;
}
.back-btn:hover {
  text-decoration: underline;
}
.reader-meta h4 {
  font-size: 1.1rem;
  color: var(--text-dark);
  margin: 0 0 0.5rem 0;
}
.reader-meta p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
}
.reader-meta .date {
  font-size: 0.8rem;
  margin-top: 0.25rem;
}

.reader-body {
  flex: 1;
  padding: 0;
  background: #f8fafc;
  overflow: hidden;
}
.email-iframe {
  width: 100%;
  height: 100%;
  border: none;
  padding: 1.5rem;
  background: transparent;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.info-block h4 {
  font-size: 1.15rem;
  color: var(--accent, #0055ff);
  border-bottom: 2px solid var(--glass-border, rgba(255, 255, 255, 0.7));
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}
.info-block p {
  color: var(--text-muted, #475569);
  font-size: 0.95rem;
  line-height: 1.6;
}

@media (max-width: 1024px) {
  .page-wrapper {
    width: 95%;
    grid-template-columns: 1fr;
  }
  .ad-space-left,
  .ad-space-right {
    display: none;
  }
}
@media (max-width: 768px) {
  .generator-layout {
    grid-template-columns: 1fr;
  }
  .action-buttons-grid {
    grid-template-columns: 1fr;
  }
  .inbox-card {
    height: 400px;
  }
}
