/* MiniBlog — mobile-first, optimized */

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

:root {
  --bg: #f8f9fa;
  --primary: #2f89fc;
  --text: #000;
  --text-muted: #666;
  --border: #ced4da;
  --footer-bg: #333;
  --footer-muted: #999;
  --footer-text: #737373;
  --radius: 5px;
  --gap: 30px;
  --section-y: 80px;
  --pad-x: 16px;
  --content-max: 1200px;
  --shadow: rgba(0, 0, 0, 0.5);
  --shadow-t: rgba(0, 0, 0, 0.7);
  --grad-card: linear-gradient(
    to bottom,
    transparent 0%,
    transparent 18%,
    var(--shadow) 99%,
    var(--shadow) 100%
  );
  --grad-trend: linear-gradient(
    to bottom,
    transparent 0%,
    transparent 18%,
    var(--shadow-t) 99%,
    var(--shadow) 100%
  );
}

html {
  overflow-x: hidden;
}

body {
  font-family: "Mulish", sans-serif;
  margin: 0;
  max-width: 100%;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
}

.container {
  width: 80%;
  max-width: 100%;
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.pd-y {
  padding-block: var(--section-y);
}

/* --- Header --- */

.header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px 24px;
  max-width: 100%;
  padding: 16px 28px 16px 18px;
}

.header .logo {
  padding-left: 5px;
  line-height: 1;
}

.header .logo a {
  font-size: 1.6em;
  line-height: 1.2;
  color: var(--text);
}

.navbar {
  margin: 0;
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-list li {
  font-weight: bold;
  line-height: 1.18;
  font-size: 1.05rem;
}

.nav-list li a {
  display: inline-block;
  padding: 6px 0;
  color: var(--text);
  font-size: 0.9em;
  line-height: 1.3;
  transition: color 0.5s;
}

.nav-list li.icon a {
  font-size: 1.0625rem;
}

.nav-list li a:hover {
  color: var(--primary);
}

/* --- Head --- */

section.head {
  background: var(--bg);
}

.head-content {
  display: grid;
  gap: var(--gap);
  grid-template-columns: 1fr;
  grid-auto-rows: minmax(200px, auto);
}

.head-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
}

.head-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--grad-card);
  z-index: 1;
}

.head-item-title,
.head-item-date {
  position: absolute;
  left: 20px;
  z-index: 2;
}

.head-item-title {
  bottom: 35px;
  font-size: 1.2em;
  font-weight: 400;
  color: #fff;
}

.head-item-date {
  bottom: 15px;
  margin-bottom: 10px;
  color: rgba(255, 255, 255, 0.5);
}

.head-img {
  width: 100%;
  height: 100%;
}

.head-img img {
  width: 100%;
  height: 100%;
}

.head-item.center {
  min-height: calc(200px + var(--gap) + 200px);
}

.center .head-img::before,
.center .head-img::after {
  position: absolute;
  bottom: 115px;
  padding: 4px 10px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #fff;
  border-radius: var(--radius);
  z-index: 2;
}

.center .head-img::before {
  content: "travel";
  left: 20px;
  background: #f23a2e;
}

.center .head-img::after {
  content: "food";
  left: 88px;
  background: var(--primary);
}

.head-img.one {
  background: url(../Images/1.jpg) center / cover;
}

.head-img.two {
  background: url(../Images/2.jpg) center / cover;
}

.head-img.three {
  background: url(../Images/3.jpg) center / cover;
}

.head-img.four {
  background: url(../Images/4.jpg) center / cover;
}

.head-img.five {
  background: url(../Images/5.jpg) center / cover;
}

/* --- Politics --- */

.Politics {
  position: relative;
}

.Politics::after {
  content: "";
  position: absolute;
  bottom: 160px;
  left: 0;
  width: 80%;
  height: 1px;
  background: #eee;
}

.Politics-item {
  margin-top: 10px;
}

.Politics-title {
  padding-bottom: 30px;
  font-weight: 400;
}

.Politics-item .Politics-type {
  display: inline-block;
  margin: 30px 20px 0;
  padding: 2px 10px;
  border-radius: var(--radius);
  background: #6c757d;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.Politics-content .Politics-item:nth-child(1) .Politics-type,
.Politics-content .Politics-item:nth-child(4) .Politics-type {
  background: #6c757d;
  color: #fff;
}

.Politics-content .Politics-item:nth-child(2) .Politics-type,
.Politics-content .Politics-item:nth-child(5) .Politics-type,
.Politics-content .Politics-item:nth-child(7) .Politics-type {
  background: #8bc34a;
  color: #fff;
}

.Politics-content .Politics-item:nth-child(3) .Politics-type {
  background: #f89d13;
  color: #fff;
}

.Politics-content .Politics-item:nth-child(6) .Politics-type,
.Politics-content .Politics-item:nth-child(8) .Politics-type,
.Politics-content .Politics-item:nth-child(9) .Politics-type {
  background: #f23a2e;
  color: #fff;
}

.Politics-content {
  display: grid;
  gap: var(--gap);
  grid-template-columns: 1fr;
}

.Politics-content-title,
.Politics-Writer,
.Politics-desc,
.Politics-item > a {
  padding-left: 20px;
}

.Politics-img {
  display: inline-block;
  width: 100%;
  height: 250px;
  border-radius: var(--radius);
}

.Politics-img img {
  width: 100%;
  height: 100%;
  max-width: 100%;
  border-radius: var(--radius);
  object-fit: cover;
}

.Politics-Writer {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 30px 0;
}

.Politics-Writer-img {
  width: 30px;
  height: 30px;
}

.Politics-Writer-img img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.Politics-Writer-Info {
  font-size: 13px;
  color: #b3b3b3;
}

.Politics-Writer-Info span a {
  color: var(--text);
}

.Politics-desc {
  max-width: 100%;
  color: var(--text-muted);
  font-size: 16px;
  font-weight: 300;
  line-height: 1.7;
}

.Politics-item > a {
  color: var(--primary);
  font-weight: 300;
}

.Politics .bullets {
  display: flex;
  justify-content: center;
  margin-top: 80px;
  text-align: center;
}

.Politics .bullets a {
  width: 40px;
  height: 40px;
  margin-left: 5px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  line-height: 40px;
}

.Politics .bullets span {
  display: inline-block;
  margin: 9px 20px 0;
  color: gray;
}

/* --- Trend --- */

section.trend {
  background: var(--bg);
}

.trend-content {
  display: grid;
  gap: var(--gap);
  grid-template-columns: 1fr;
  grid-auto-rows: minmax(300px, auto);
}

.trend-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
}

.trend-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--grad-trend);
  z-index: 1;
}

.item1 .trend-item-title {
  max-width: 20em;
  margin-bottom: 25px;
}

.item2 .trend-item-title {
  max-width: 11em;
  font-size: 1.2em;
}

.item3 .trend-item-title,
.item4 .trend-item-title {
  max-width: 16em;
  margin-bottom: 25px;
}

.item1 .trend-img::after,
.item2 .trend-img::after,
.item3 .trend-img::after,
.item4 .trend-img::after {
  content: "";
  position: absolute;
  top: 10px;
  left: 20px;
  z-index: 2;
  padding: 4px 10px;
  border-radius: var(--radius);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #fff;
}

.item1 .trend-img::after {
  content: "nature";
  background: #8bc34a;
}

.item2 .trend-img::after {
  content: "travel";
  background: #f23a2e;
}

.item3 .trend-img::after {
  content: "sports";
  background: var(--primary);
}

.item4 .trend-img::after {
  content: "lifestyle";
  background: #f89d13;
}

.trend-img {
  width: 100%;
  height: 100%;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.trend-img img {
  width: 100%;
  height: 100%;
}

.trend-img.one {
  background-image: url(../Images/1.jpg);
}

.trend-img.two {
  background-image: url("../Images/Section 2/6.jpg");
}

.trend-img.three {
  background-image: url("../Images/Section 2/2.jpg");
}

.trend-img.four {
  background-image: url("../Images/Section 2/3.jpg");
}

.trend-item-title,
.trend-item-date {
  position: absolute;
  left: 20px;
  z-index: 2;
}

.trend-item-title {
  bottom: 35px;
  font-size: 1.2em;
  font-weight: 400;
  color: #fff;
}

.trend-item-date {
  bottom: 15px;
  margin-bottom: 10px;
  color: rgba(255, 255, 255, 0.5);
}

/* --- Contact --- */

.contact-item {
  width: 100%;
  max-width: 28rem;
  margin-inline: auto;
  text-align: center;
}

.contact-title {
  font-size: 20px;
  font-weight: 400;
}

.contact-desc {
  color: var(--text-muted);
  font-size: 16px;
  font-weight: 300;
  line-height: 1.7;
}

.input-group {
  display: flex;
  margin-top: 50px;
  text-align: center;
}

input[type] {
  flex: 1;
  min-width: 0;
  height: 43px;
  padding-left: 10px;
  border: 1px solid var(--border);
  outline: none;
  font-size: 16px;
}

input:focus {
  border-color: var(--primary);
}

input::placeholder {
  font-size: 16px;
}

.contact-item button {
  display: inline-block;
  padding: 10px;
  border: none;
  background: var(--primary);
  color: #fff;
  font-size: 15px;
}

/* --- Footer --- */

.footer {
  padding-bottom: 40px;
  background: var(--footer-bg);
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 40px;
  padding: 60px 0 40px;
  color: rgb(153, 153, 153);
}

.footer-item:first-child {
  flex: 1 1 220px;
  min-width: 0;
}

.footer-item:nth-child(2) {
  flex: 0.7 1 180px;
  min-width: 0;
  text-align: center;
}

.footer-item:nth-child(3) {
  flex: 1 1 220px;
  min-width: 0;
  text-align: center;
}

.footer-item:nth-child(3) .footer-item-title {
  margin-left: 25px;
  text-align: left;
  color: #fff;
}

.footer-item-title {
  color: #fff;
  font-weight: 300;
  font-size: 1em;
}

.footer-item-desc {
  max-width: 85%;
  margin-top: 30px;
  color: var(--footer-text);
  font-weight: 300;
  line-height: 1.6;
}

.footer-links {
  display: grid;
  max-width: 100%;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px 24px;
}

.footer-links a {
  display: block;
  margin-bottom: 5px;
  color: var(--footer-muted);
  font-size: 1em;
  font-weight: 300;
}

.footer-social-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 25px 0 0;
  padding: 0;
  list-style: none;
}

.footer-item:nth-child(3) .footer-social-list {
  margin-left: 20px;
}

.footer-social-list li {
  margin: 0;
  color: rgb(153, 153, 153);
}

.footer-social-list li a i {
  color: rgb(153, 153, 153);
}

.footer-copyrights {
  margin-top: 40px;
  padding-bottom: 50px;
  text-align: center;
  color: var(--footer-text);
}

.footer-copyrights i {
  color: red;
}

.footer-copyrights a {
  color: var(--footer-muted);
}

/* Footer: center all blocks on mobile only (not tablet) */
@media (max-width: 35.99875rem) {
  /* 576px — typical phone widths; 40rem+ tablet keeps default footer alignment */
  .footer-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-item {
    width: 100%;
    max-width: 28rem;
    text-align: center;
  }

  .footer-item-desc {
    margin-inline: auto;
  }

  .footer-item:nth-child(3) .footer-item-title {
    margin-left: 0;
    text-align: center;
  }

  .footer-item:nth-child(3) .footer-social-list {
    margin-left: 0;
    justify-content: center;
  }

  .footer-links {
    margin-inline: auto;
    justify-items: center;
  }
}

/* --- Tablet --- */

@media (min-width: 40rem) {
  .Politics-content {
    grid-template-columns: repeat(2, 1fr);
  }

  .Politics-desc {
    max-width: 315px;
  }
}

/* --- Desktop (original layout) --- */

@media (min-width: 60rem) {
  .head-content {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 200px);
    grid-auto-rows: unset;
  }

  .head-item.center {
    grid-column: 2 / 3;
    grid-row: 1 / 3;
    min-height: unset;
  }

  .Politics-content {
    grid-template-columns: repeat(3, 1fr);
  }

  .trend-content {
    grid-template-columns: repeat(2, 1fr) 1.25fr;
    grid-template-rows: repeat(2, 300px);
    grid-auto-rows: unset;
  }

  .item1 {
    grid-column: 1 / 3;
  }

  .item2 {
    grid-column: 3 / 4;
    grid-row: 1 / 3;
  }

  .item2 .trend-item-title {
    font-size: 1.6em;
  }

  .item3 {
    grid-area: 2 / 1 / 3 / 2;
  }

  .contact-item {
    width: 40%;
    max-width: none;
  }
}

@media (min-width: 75rem) {
  .container {
    max-width: min(var(--content-max), 100%);
  }
}
