page-campus-life.php 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676
  1. <?php
  2. /**
  3. * Template Name: Campus Life
  4. *
  5. * @package UIU_DEPARTMENTAL
  6. */
  7. get_header(); ?>
  8. <?php while (have_posts()) : the_post(); ?>
  9. <main id="main" class="site-main" role="main">
  10. <div id="campus-life">
  11. <div class="hero-section">
  12. <iframe src="https://www.youtube.com/embed/MfVYcMmbHuk?controls=0&disablekb=1&autoplay=1&mute=1&playsinline=1&loop=1&playlist=MfVYcMmbHuk" allowfullscreen></iframe>
  13. <div class="hero-content">
  14. <h1 class="hero-title">Virtual Campus Tour</h1>
  15. <p class="hero-sub-title">
  16. Lorem ipsum dolor sit amet consectetur adipisicing elit. Repellat vero reprehenderit ab hic sunt optio.
  17. </p>
  18. </div>
  19. </div>
  20. <!-- Getting Around -->
  21. <?php
  22. $args = array(
  23. 'post_type' => 'campus-life',
  24. 'tag' => 'featured-campus-life',
  25. 'posts_per_page' => 1,
  26. 'post__not_in' => array(get_the_ID()),
  27. 'orderby' => 'date',
  28. 'order' => 'DESC',
  29. );
  30. $query = new WP_Query($args);
  31. if ($query->have_posts()) :
  32. while ($query->have_posts()) :
  33. $query->the_post(); ?>
  34. <div class="getting-around">
  35. <div class="container">
  36. <h1 class="title">
  37. Getting Around
  38. </h1>
  39. <div class="content">
  40. <div class="text-content">
  41. <p>
  42. <?php the_excerpt(); ?>
  43. </p>
  44. <a class="link" href="">Read in detail</a>
  45. </div>
  46. <div class="image-content">
  47. <img src="<?php echo get_the_post_thumbnail_url(); ?>" alt="">
  48. </div>
  49. </div>
  50. </div>
  51. </div>
  52. <?php
  53. endwhile;
  54. // else :
  55. // echo '<div class="no-post-found">No student life has found! </div>';
  56. endif;
  57. wp_reset_query();
  58. ?>
  59. <div class="campus-content student-life">
  60. <div class="container-fluid">
  61. <h1 class="title">Student Life</h1>
  62. <div class="content content-three">
  63. <?php
  64. $args = array(
  65. 'post_type' => 'campus-life',
  66. 'category_name' => 'student-life',
  67. 'posts_per_page' => 3,
  68. 'post__not_in' => array(get_the_ID()),
  69. 'orderby' => 'date',
  70. 'order' => 'DESC',
  71. );
  72. $query = new WP_Query($args);
  73. if ($query->have_posts()) :
  74. while ($query->have_posts()) :
  75. $query->the_post(); ?>
  76. <div class="single-content">
  77. <div class="image-container">
  78. <div class="bg-img" style="background-image: url(<?php echo get_the_post_thumbnail_url(); ?>"></div>
  79. </div>
  80. <div class="details">
  81. <h4 class="content-title"><?php echo get_the_title(); ?></h4>
  82. <p class="content-detail">
  83. <?php the_excerpt(); ?>
  84. </p>
  85. <a class="link" href="<?php echo get_permalink(); ?>">View details</a>
  86. </div>
  87. </div>
  88. <?php
  89. endwhile;
  90. else :
  91. echo '<div class="no-post-found">No student life has found! </div>';
  92. endif;
  93. wp_reset_query(); ?>
  94. </div>
  95. </div>
  96. </div>
  97. <!-- Arts & Culture -->
  98. <div class="campus-content arts-culture">
  99. <div class="container">
  100. <h1 class="title">Arts & Culture</h1>
  101. <div class="content content-two">
  102. <?php
  103. $args = array(
  104. 'post_type' => 'campus-life',
  105. 'category_name' => 'arts-and-culture',
  106. 'posts_per_page' => 2,
  107. 'post__not_in' => array(get_the_ID()),
  108. 'orderby' => 'date',
  109. 'order' => 'DESC',
  110. );
  111. $query = new WP_Query($args);
  112. if ($query->have_posts()) :
  113. while ($query->have_posts()) :
  114. $query->the_post(); ?>
  115. <div class="single-content">
  116. <div class="image-container">
  117. <div class="bg-img" style="background-image: url(<?php echo get_the_post_thumbnail_url(); ?>"></div>
  118. </div>
  119. <div class="details">
  120. <h4 class="content-title"><?php echo get_the_title(); ?></h4>
  121. <p class="content-detail">
  122. <?php the_excerpt(); ?>
  123. </p>
  124. <a class="link" href="<?php echo get_permalink(); ?>">View details</a>
  125. </div>
  126. </div>
  127. <?php
  128. endwhile;
  129. else :
  130. echo '<div class="no-post-found">No Arts & Culture post has found! </div>';
  131. endif;
  132. wp_reset_query(); ?>
  133. </div>
  134. </div>
  135. </div>
  136. <!-- Recreation and Wellness -->
  137. <div class="campus-content recreation-and-wellness">
  138. <div class="container-fluid">
  139. <h1 class="title">Athletics, Recreation, & Wellness</h1>
  140. <div class="content content-three">
  141. <?php
  142. $args = array(
  143. 'post_type' => 'campus-life',
  144. 'category_name' => 'recreation-and-wellness',
  145. 'posts_per_page' => 3,
  146. 'post__not_in' => array(get_the_ID()),
  147. 'orderby' => 'date',
  148. 'order' => 'DESC',
  149. );
  150. $query = new WP_Query($args);
  151. if ($query->have_posts()) :
  152. while ($query->have_posts()) :
  153. $query->the_post(); ?>
  154. <div class="single-content">
  155. <div class="image-container">
  156. <div class="bg-img" style="background-image: url(<?php echo get_the_post_thumbnail_url(); ?>"></div>
  157. </div>
  158. <div class="details">
  159. <h4 class="content-title"><?php echo get_the_title(); ?></h4>
  160. <p class="content-detail">
  161. <?php the_excerpt(); ?>
  162. </p>
  163. <a class="link" href="<?php echo get_permalink(); ?>">View details</a>
  164. </div>
  165. </div>
  166. <?php
  167. endwhile;
  168. else :
  169. echo '<div class="no-post-found">No Recreation & Wellness post has found! </div>';
  170. endif;
  171. wp_reset_query(); ?>
  172. </div>
  173. </div>
  174. </div>
  175. <!-- campus statistics -->
  176. <div class="state">
  177. <div class="container-fluid analytics">
  178. <div class="item">
  179. <h2 class="count">600+</h2>
  180. <p class="desc">Organized student groups</p>
  181. </div>
  182. <div class="item">
  183. <h2 class="count">69</h2>
  184. <p class="desc">Undergraduate student residences</p>
  185. </div>
  186. <div class="item">
  187. <h2 class="count">20000+</h2>
  188. <p class="desc">Students living on campus</p>
  189. </div>
  190. </div>
  191. </div>
  192. </div>
  193. </main>
  194. <!-- #main -->
  195. <?php endwhile; // end of the loop.
  196. ?>
  197. <style>
  198. #main {
  199. padding-top: unset;
  200. }
  201. #campus-life {
  202. font-family: "DM Serif Text", serif;
  203. }
  204. #campus-life .hero-section {
  205. position: relative;
  206. height: 100vh;
  207. overflow: hidden;
  208. }
  209. @media screen and (max-width: 1000px) {
  210. #campus-life .hero-section {
  211. height: 75vh;
  212. margin-top: 90px;
  213. }
  214. }
  215. @media screen and (max-width: 800px) {
  216. #campus-life .hero-section {
  217. height: 65vh;
  218. }
  219. }
  220. @media screen and (max-width: 500px) {
  221. #campus-life .hero-section {
  222. margin-top: 40px;
  223. height: 58vh;
  224. }
  225. }
  226. #campus-life .hero-section iframe {
  227. height: 100%;
  228. width: 100vw;
  229. border: none;
  230. transform: scaleX(1.5) scaleY(1.8);
  231. }
  232. #campus-life .hero-section .hero-content {
  233. background: rgba(0, 0, 0, 0.3);
  234. position: absolute;
  235. top: 0;
  236. left: 0;
  237. right: 0;
  238. bottom: 0;
  239. z-index: 10;
  240. display: flex;
  241. flex-direction: column;
  242. justify-content: flex-end;
  243. text-align: left;
  244. padding-left: 5rem;
  245. padding-bottom: 3rem;
  246. }
  247. @media screen and (max-width: 1000px) {
  248. #campus-life .hero-section .hero-content {
  249. padding-left: 1rem;
  250. }
  251. }
  252. @media screen and (max-width: 500px) {
  253. #campus-life .hero-section .hero-content {
  254. padding-left: 0.75rem;
  255. padding-bottom: 0.25rem;
  256. }
  257. }
  258. #campus-life .hero-section .hero-content .hero-title {
  259. margin-top: auto;
  260. margin-bottom: 0.25rem !important;
  261. font-size: 3rem;
  262. color: #ffffff;
  263. text-shadow: 3px 4px 10px #111010;
  264. }
  265. @media screen and (max-width: 500px) {
  266. #campus-life .hero-section .hero-content .hero-title {
  267. font-size: 1.2rem;
  268. }
  269. }
  270. #campus-life .hero-section .hero-content .hero-sub-title {
  271. display: inline-block !important;
  272. max-width: 750px !important;
  273. color: #d7d7d7;
  274. font-size: 1.2rem;
  275. text-shadow: 3px 4px 10px #111010;
  276. }
  277. @media screen and (max-width: 500px) {
  278. #campus-life .hero-section .hero-content .hero-sub-title {
  279. font-size: 0.75rem;
  280. }
  281. }
  282. #campus-life .hero-section .page-title {
  283. text-align: center;
  284. font-size: 2.5rem;
  285. }
  286. #campus-life .hero-section .page-subtitle {
  287. color: #7d7d7d;
  288. font-size: 1.1rem;
  289. text-align: center;
  290. margin-left: auto;
  291. margin-right: auto;
  292. margin-bottom: unset;
  293. max-width: 650px !important;
  294. }
  295. #campus-life .hero-section .campus-hero {
  296. padding-top: 2rem;
  297. }
  298. #campus-life .hero-section .image-container {
  299. width: 100%;
  300. }
  301. #campus-life .hero-section .image-container img {
  302. width: 100%;
  303. }
  304. #campus-life .hero-section .analytics {
  305. margin: 3.8rem 0;
  306. padding: 1.2rem 0 0.5rem;
  307. border-top: 2px solid #333;
  308. border-bottom: 2px solid #333;
  309. text-align: center;
  310. display: flex;
  311. justify-content: space-around;
  312. align-items: center;
  313. }
  314. @media screen and (max-width: 500px) {
  315. #campus-life .hero-section .analytics {
  316. flex-direction: column;
  317. }
  318. }
  319. #campus-life .hero-section .analytics .item {
  320. margin-bottom: 1rem;
  321. }
  322. #campus-life .hero-section .analytics .count {
  323. font-weight: 700;
  324. margin-bottom: 0.5rem !important;
  325. }
  326. #campus-life .hero-section .analytics .title {
  327. font-weight: 500;
  328. margin-bottom: unset;
  329. }
  330. #campus-life .campus-content {
  331. padding: 4rem 2rem 3rem;
  332. }
  333. @media screen and (max-width: 767px) {
  334. #campus-life .campus-content {
  335. padding: 2rem 0;
  336. }
  337. }
  338. #campus-life .campus-content .title {
  339. text-align: center;
  340. }
  341. #campus-life .campus-content .content {
  342. padding: 3rem 0;
  343. }
  344. #campus-life .campus-content .content .single-content {
  345. overflow: hidden;
  346. }
  347. #campus-life .campus-content .content .single-content:hover .bg-img {
  348. transform: scale(1.1);
  349. }
  350. #campus-life .campus-content .content .image-container {
  351. height: 300px;
  352. width: 100%;
  353. border-radius: 5px;
  354. overflow: hidden;
  355. }
  356. #campus-life .campus-content .content .image-container .bg-img {
  357. height: 100%;
  358. background-size: cover;
  359. background-position: center;
  360. background-repeat: no-repeat;
  361. transition: all 4.5s;
  362. }
  363. #campus-life .campus-content .content .details {
  364. padding: 0 0.5rem 1rem;
  365. }
  366. #campus-life .campus-content .content .content-title {
  367. text-align: left;
  368. margin-top: 0.5rem;
  369. margin-bottom: unset !important;
  370. text-transform: capitalize;
  371. }
  372. #campus-life .campus-content .content .content-detail {
  373. margin-top: 0.5rem;
  374. margin-bottom: unset;
  375. font-size: 0.8rem;
  376. line-height: 1.7;
  377. }
  378. #campus-life .campus-content .content .link {
  379. margin-top: 0.5rem;
  380. display: inline-block;
  381. padding: 0.35rem 0.85rem;
  382. color: #fff;
  383. background: #915416;
  384. font-size: 0.75rem;
  385. text-transform: capitalize;
  386. border-radius: 5px;
  387. }
  388. #campus-life .campus-content .content .link:hover {
  389. background: #e17f1d;
  390. }
  391. #campus-life .campus-content .content-two {
  392. display: flex;
  393. flex-wrap: wrap;
  394. justify-content: center;
  395. gap: 2rem;
  396. }
  397. #campus-life .campus-content .content-two .single-content {
  398. text-align: left;
  399. width: calc(50% - 2rem);
  400. }
  401. @media screen and (max-width: 767px) {
  402. #campus-life .campus-content .content-two .single-content {
  403. width: 100%;
  404. }
  405. }
  406. #campus-life .campus-content .content-three {
  407. display: flex;
  408. flex-wrap: wrap;
  409. justify-content: center;
  410. gap: 2rem;
  411. }
  412. #campus-life .campus-content .content-three .single-content {
  413. text-align: left;
  414. width: calc(33.33% - 2rem);
  415. }
  416. @media screen and (max-width: 1000px) {
  417. #campus-life .campus-content .content-three .single-content {
  418. width: calc(50% - 2rem);
  419. }
  420. }
  421. @media screen and (max-width: 767px) {
  422. #campus-life .campus-content .content-three .single-content {
  423. width: 100%;
  424. }
  425. }
  426. #campus-life .student-life {
  427. padding-top: 5rem;
  428. margin-top: 0;
  429. }
  430. #campus-life .student-life,
  431. #campus-life .recreation-and-wellness {
  432. background: #f4f4f4;
  433. }
  434. #campus-life .getting-around {
  435. padding-top: 4rem;
  436. padding-bottom: 7rem;
  437. }
  438. @media screen and (max-width: 1000px) {
  439. #campus-life .getting-around {
  440. padding-top: 3rem;
  441. padding-bottom: 1rem;
  442. }
  443. }
  444. @media screen and (max-width: 767px) {
  445. #campus-life .getting-around {
  446. padding-top: 2rem;
  447. padding-bottom: 2rem;
  448. }
  449. }
  450. #campus-life .getting-around .title {
  451. text-align: center;
  452. }
  453. #campus-life .getting-around .content {
  454. margin: 4rem 0;
  455. display: grid;
  456. grid-template-columns: repeat(2, 1fr);
  457. }
  458. @media screen and (max-width: 992px) {
  459. #campus-life .getting-around .content {
  460. display: block;
  461. }
  462. }
  463. #campus-life .getting-around .content .text-content {
  464. padding: 2rem 3rem 2rem 2rem;
  465. background: #f4f4f4;
  466. width: 100%;
  467. border-radius: 3px;
  468. }
  469. #campus-life .getting-around .content .text-content p {
  470. font-size: 0.9rem;
  471. margin-bottom: 0.25rem;
  472. }
  473. #campus-life .getting-around .content .text-content .link {
  474. display: block;
  475. width: -moz-fit-content;
  476. width: fit-content;
  477. margin-top: 0.5rem;
  478. font-size: 0.95rem;
  479. font-weight: 600;
  480. color: #915416;
  481. }
  482. #campus-life .getting-around .content .text-content .link:hover {
  483. color: #633a10;
  484. }
  485. #campus-life .getting-around .content .image-content {
  486. width: 100%;
  487. transform: translateY(100px) translateX(-2rem);
  488. border-radius: 3px;
  489. overflow: hidden;
  490. }
  491. @media screen and (max-width: 992px) {
  492. #campus-life .getting-around .content .image-content {
  493. width: 80%;
  494. transform: translateY(-10%) translateX(30%);
  495. }
  496. }
  497. @media screen and (max-width: 500px) {
  498. #campus-life .getting-around .content .image-content {
  499. margin-top: 2.5rem;
  500. width: 100%;
  501. transform: translateY(0) translateX(0);
  502. }
  503. }
  504. #campus-life .getting-around .content .image-content img {
  505. width: 100%;
  506. }
  507. #campus-life .campus-tour {
  508. margin: 2rem 0 0;
  509. padding: 2rem 0;
  510. background: #f4f4f4;
  511. }
  512. #campus-life .campus-tour .title {
  513. text-align: center;
  514. }
  515. #campus-life .campus-tour .content {
  516. width: 100%;
  517. margin-top: 2rem;
  518. }
  519. #campus-life .campus-tour .content .wraper-iframe {
  520. position: relative;
  521. width: 100%;
  522. }
  523. #campus-life .campus-tour .content iframe {
  524. aspect-ratio: 16/6;
  525. width: 100%;
  526. border-radius: 10px;
  527. }
  528. #campus-life .state {
  529. padding: 4rem 0 3rem;
  530. }
  531. #campus-life .state .analytics {
  532. border-top: 2px solid #333;
  533. border-bottom: 2px solid #333;
  534. text-align: center;
  535. display: flex;
  536. justify-content: space-around;
  537. align-items: center;
  538. }
  539. @media screen and (max-width: 768px) {
  540. #campus-life .state .analytics {
  541. flex-direction: column;
  542. }
  543. }
  544. #campus-life .state .analytics .item {
  545. margin-bottom: 1rem;
  546. }
  547. #campus-life .state .analytics .count {
  548. font-weight: 700;
  549. margin-bottom: 0.5rem !important;
  550. font-size: 2rem;
  551. }
  552. #campus-life .state .analytics .desc {
  553. font-weight: 500;
  554. margin-bottom: unset;
  555. }
  556. </style>
  557. <?php get_footer(); ?>